Where is virtualenvwrapper.sh after pip install?

后端 未结 24 1451
忘了有多久
忘了有多久 2020-12-07 09:20

I\'m trying to setup virtualenvwrapper on OSX, and all the instructions and tutorials I\'ve found tell me to add a source command to .profile, pointing towards virtualenvwra

相关标签:
24条回答
  • 2020-12-07 10:00

    In OS X 10.8.2, with Python 2.7:

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

    0 讨论(0)
  • Using

    find / -name virtualenvwrapper.sh
    

    I got a TON of "permissions denied"s, and exactly one printout of the file location. I missed it until I found that file location when I uninstall/installed it again with pip.

    In case you were curious, it was in

    /usr/local/share/python/virtualenvwrapper.sh
    
    0 讨论(0)
  • 2020-12-07 10:00

    In my case (OSX El Capitan, version 10.11.5) I needed to edit the .profile like so:

    In the terminal:

    vim ~/.profile

    export WORKON_HOME=$HOME/.virtualenvs
    export MSYS_HOME=C:\msys\1.0
    source /Library/Frameworks/Python.framework/Versions/2.7/bin/virtualenvwrapper.sh                                                                                   
    

    And then reload the profile (that it will be availuble in the current session.)

    source ~/.profile

    Hope it will help someone.

    0 讨论(0)
  • 2020-12-07 10:02

    Although this is an OS X question, here's what worked for me on Linux (Red Hat).

    My virtualwrapper.sh was in

    ~/.local/bin/virtualenvwrapper.sh
    

    This is probably because I installed virtualenvwrapper locally, using the --user flag...

    pip install --user virtualenvwrapper
    

    ...as an alternative to the risky practice of using sudo pip.

    0 讨论(0)
  • 2020-12-07 10:04

    On Mac OS

    which virtualenvwrapper.sh
    

    u got

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

    and u can

    sudo ln /Library/Frameworks/Python.framework/Versions/2.7/bin/virtualenvwrapper.sh /usr/local/bin/virtualenvwrapper.sh
    

    and in your .bash_profile

    source /usr/local/bin/virtualenvwrapper.sh
    

    or u can

    source /Library/Frameworks/Python.framework/Versions/2.7/bin/virtualenvwrapper.sh
    
    0 讨论(0)
  • 2020-12-07 10:04

    I have the same problem. If you have older version of virtualenvwrapper, then pip wont work.

    download src from http://pypi.python.org/pypi/virtualenvwrapper/3.6 and python setup.py install. Then the problem solved.

    0 讨论(0)
提交回复
热议问题