I'm trying to use PIP on my server but something weird happens.
So, I have python 2.7.2 installed, in fact when I run python -V
I get:
Python 2.7.2
Then, in my .bashrc
this is what I have:
export PATH=$HOME/.local/bin:$HOME/.local/usr/bin:$PATH
export PATH=$HOME/python/Python-2.7.2/:$PATH
export PYTHONPATH=$HOME/python/lib/python2.7/site-packages:$PYTHONPATH
I'm sure that the last one is correct because when I do cd $HOME/python/lib/python2.7/site-packages
, I get:
./ pip-1.4.1-py2.7.egg-info/
../ setuptools-0.6c11-py2.7.egg-info
README setuptools-2.0.2-py2.7.egg/
distribute-0.6.49-py2.7.egg/ setuptools-2.0.2-py2.7.egg.OLD.1388586026.24
easy-install.pth setuptools.pth
pip/
But then, if I try to use PIP, I get:
-bash: pip: command not found
pip
可执行文件不在您的PATH中(它应该在/usr/local/bin/pip
,因此您需要在/usr/local/bin
中包含-usr或-maybe- $HOME/.local/usr/local/bin
根据您的.bashrc
)。
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.