mkvirtualenv命令未找到,在运行source ~/.bash_profile后

2024-04-20 06:40:29 发布

您现在位置:Python中文网/ 问答频道 /正文

我正在为newcoder.io上的教程进行设置。我正在安装xubuntu,它运行在Windows7上的OracleVM中。在我安装virtualenv和virtualenvwrapper之前,一切都顺利进行。在

 sudo pip install virtualenv
 sudo pip install virtualenvwrapper
 export WORKON_HOME=~/Envs
 echo 'export WORKON_HOME=~/Envs' >> ~/.bash_profile
 echo 'source /etc/bash_completion.d/virtualenvwrapper' >> ~/.bash_profile
 mkdir -p $WORKON_HOME
 source ~/.bash_profile

我跑完之后

^{pr2}$

我有个错误说:

 mkvirtualenv: command not found

有什么办法可以补救?在


Tags: installpipioechobashsourcehomevirtualenv
2条回答

尝试在/etc/bash_completion.d/virtualenvwrapper命令之前,在.bash_profile中运行virtualenvwrapper.sh。例如:

.bash_配置文件

...
source "/usr/bin/virtualenvwrapper.sh"
source /etc/bash_completion.d/virtualenvwrapper

几天前,我安装了virtualenvwrapper,我所要做的就是再次登录我的帐户。不需要对.bashrc或.bash_配置文件进行任何更改。在

相关问题 更多 >