I couldn't get virtualenv
to work despite various attempts. I installed virtualenv
on MAC OS X using:
pip install virtualenv
and have also added the PATH
into my .bash_profile
. Every time I try to run the virtualenv
command, it returns:
-bash: virtualenv: command not found
Every time I run pip install virtualenv
, it returns:
Requirement already satisfied (use --upgrade to upgrade): virtualenv in /Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages
I understand that in mac, the virtualenv
should be correctly installed in
/usr/local/bin
The virtualenv
is indeed installed in /usr/local/bin
, but whenever I try to run the virtualenv
command, the command is not found. I've also tried to run the virtualenv
command in the directory /usr/local/bin
, and it gives me the same result:
-bash: virtualenv: command not found
These are the PATHs I added to my .bash_profile
export PATH=$PATH:/usr/local/bin
export PATH=$PATH:/usr/local/bin/python
export PATH=$PATH:/Library/Framework/Python.framework/Version/2.7/lib/site-packages
Any workarounds for this? Why is this the case?
$ ln -s /usr/bin/virtualenv /Library/Framework/Python.framework/Version/2.7/lib/site-packages/virtualenv/virtualenv.py
– Justin Fayln -s /Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/virtualenv.py /usr/local/bin/virtualenv
– Aliza