System: Mountain Lion 10.8.
I tried to uninstall python 2.7 and therefore i also deleted /usr/bin/python.
However, after that i needed python again and i installed in again.
Now I want to use easy_install to install matlibplot etc..
Unfortunately, it says:
-bash: /usr/bin/easy_install: /usr/bin/python: bad interpreter: No such file or directory
and also /usr/bin/python:
-bash: /usr/bin/python: No such file or directory
however if i go to /usr/bin/ there are all version of python.
I also took a look to /usr/bin/easy_install; the first line says:
#!/usr/bin/python
BTW: i also installed python 3.2 and it also not "visible" outside /usr/bin
Do I need to fix any path variables?
Thanks for your help!
Best Answer
As you mentioned in the comment,
ls -l /usb/bin/python*
shows:Note that there is no
/usr/bin/python
.As @Wouter mentioned, you'll want to create a symlink:
That'll create a symlink (think of it as a shortcut in Windows), from
/usr/bin/python
to/usr/bin/python2.6
For a bit more detail, you mention the first line of
/usr/bin/easy_install
is :This is commonly known as the shebang line, and tells the script which interpretor to use - in this case it's trying to use
/usr/bin/python
, which, as we've seen from the ls command, does not exist, which is why we create a symlink