Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

Already on GitHub? Sign in to your account

Installing npm on production Server broke other server Software #2678

Closed
markfermor opened this Issue Aug 6, 2012 · 2 comments

Comments

Projects
None yet
2 participants

Hi Guys,

We installed npm on a server a week or so ago and had no problems. Today however we restarted a different program running on that Linux server and it didn't start-up or run at all correctly.

Have worked out why and its because of

https://raw.github.com/isaacs/npm/caafb7323708e113d100e3e8145b949ed7a16c22/lib/utils/completion.sh

Specifically:-
COMP_WORDBREAKS=${COMP_WORDBREAKS/=/}
COMP_WORDBREAKS=${COMP_WORDBREAKS/@/}
export COMP_WORDBREAKS

Removing characters from this variable which is potentially used by other software on the server (or in our case, is used) has caused us a bit of a problem.

I think this method should perhaps be reviewed and amended so that installing npm cannot cause problems for other programs that also make use of that variable.

What might be the reason/s NPM needs this to happen and if we changed it so on our systems where NPM is installed, to use what exists by default might we end up breaking on the NPM side?

Many Thanks

Owner

isaacs commented Aug 7, 2012

The npm tab-completion is only added if you explicitly add it to your session. If you don't like that, then don't do that.

I'd happily accept a patch to do this in a more localized way if it doesn't break the npm completion for other users. Otherwise, just don't use npm completion.

Closed: Working as designed.

@isaacs isaacs closed this Aug 7, 2012

Hi Isaac,

Many thanks for your response, I would say maybe it's the way the Debian package installs npm. Its put the completion script into a place where it will be run for every session, I can understand why it would be like that, however I'm also happy to know we can easily remove.

Cheers

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment