Problem with virtualenv in Mac OS X

前端 未结 14 2060
情歌与酒
情歌与酒 2020-12-23 16:29

I\'ve installed virtualenv via pip and get this error after creating a new environment:

selenium:~ auser$ virtualenv new  
New pyt         


        
14条回答
  •  轮回少年
    2020-12-23 17:12

    Open terminal and type /Library/Frameworks/Python.framework/Versions/

    then type ls /Library/Frameworks/Python.framework/Versions/2.7/bin/ if you are using Python2(or any other else).

    Edit ~/.bash_profile and add the following line: export PATH=$PATH:/Library/Frameworks/Python.framework/Versions/2.7/bin/

    cat ~/.bash_profile

    In my case the content of ~/.bash_profile is as follows:

    export PATH=$PATH:/Library/Frameworks/Python.framework/Versions/2.7/bin/

    Now the virtualenv command should work.

提交回复
热议问题