virtualenv “workon” doesn't work

后端 未结 2 522
后悔当初
后悔当初 2021-01-03 08:03

I made a virtualenv environment for a project. \"workon projectname\" worked and activated the environment but after I shut down my laptop it starts not working. Could someo

2条回答
  •  粉色の甜心
    2021-01-03 08:41

    In my case I need to do the following steps (on Mac OS X 10.11):

    I added this line:

    source "/Library/Frameworks/Python.framework/Versions/2.7/bin/virtualenvwrapper.sh"
    

    to my ~/.bash_profile

    And afterwards, following Eric Scrivner instructions, I created a folder at /opt/ called virtual_env using sudo mkdir /opt/virtual_env

    And finally, I run the command sudo chown -R youruser /opt/virtual_env

    And than: source ~/.bash_profile

提交回复
热议问题