This repository has been archived by the owner on Aug 11, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 3k
npm munges path #2886
Comments
I don't think that this is a problem that can be solved in a general way. Take it up with the CentOS rulers who decided that it was a good idea to have multiple different versions of python all installed at the same time. I think you can set the PYTHON environment variable to |
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
I'm trying to debug an error I'm getting when installing
gitteh
. I'm running on CentOS 5.8, whose/usr/bin/python
is 2.4. I've gotpython2.6
on the path and when I built my RPM for nodejs I modified all instances of#!/usr/bin/env python
→#!/usr/bin/env python2.6
, but that's not sufficient for scripts (likewaf
) that use#!/usr/bin/env python
. So, as a total kludge I created~/tmp/path_whackamole
, created a symlink from/usr/bin/python2.6
to~/tmp/path_whackamole/python
and put~/tmp/path_whackamole
first on the path.npm's
lib/utils/lifecycle.js
adds a couple of elements onto the front of the PATH and blindly assumes that I want/usr/bin
(the path wherenode
lives) first. I do not.npm
andnode
are in/usr/bin
. I'm attempting to install a package from~/tmp/package
. ExistingPATH
is/home/blalor/tmp/path_whackamole:/usr/kerberos/bin:/usr/local/bin:/bin:/usr/bin:/home/blalor/bin
What npm actually does:
I suppose what npm should do is up for debate, I suppose, but I don't want my
PATH
to be smashed…The text was updated successfully, but these errors were encountered: