pip
我在 Linux shell 的 Windows 系统中安装了 python 3 ,但site-packages
如果我想运行任何 python 包可执行文件,我似乎必须手动查找并指定目录。我想使用的软件包是cheat和awscli,但任何软件包的问题都是相同的。
我的命令链是:
sudo apt-get update
(因为sudo apt-get install pip3
在全新安装时不起作用)sudo apt-get install pip3
(也安装了python)sudo pip3 install cheat
cheat
不被识别为命令,而python3
运行良好
/usr/bin/python3
$HOME/.local/lib/python3.6/site-packages
必须在路上~/.profile
添加$HOME/.local/lib/python3.6/site-packages
到路径中export PATH="$HOME/.local/lib/python3.6/site-packages:PATH"
~/.profile
我可以在安装过程中更改一些内容,这样我就不必搜索site-packages
目录并将其手动添加到路径中?
更新:为 pip 执行的正确调用是sudo pip3 install cheat
。pip
系统上没有明文。调用pip
会导致错误Command 'pip' not find。