npm comes with node now. What does this mean?

node.js, npm

Solution

- Yes, the nodejs package includes both `node` and `npm` executables. The code for each has its own repo, but when packaged both are included.

- npm source: https://github.com/isaacs/npm

- node source: https://github.com/joyent/node

- When you install that .deb file from the PPA, you should get both `/usr/bin/nodejs` and `/usr/bin/npm` and 2 symlinks at `/usr/bin/node` (which points to) `/etc/alternatives/node` (which points to `/usr/bin/nodejs`).

- If any of this isn't true, your install didn't fully succeed, most likely due to conflicting files you left around from your manual install. I would suggest uninstalling the .deb then making sure there are no stale files left from your manual install and then installing again.

Problem

Node noob here. I had previously installed both npm and node separately. Apparently, npm comes with node now. (link) To my newbie mind, this means my previous dual installation is old and ugly. 1 binary > 2 binaries. So i uninstalled both. Then I installed the latest node following the procedure. (i am running eOS) Terminal ``` user@box:-$ which node /usr/bin/node user@box:-$ node -v v0.10.22 user@box:-$ which npm user@box:-$ npm -v bash: /usr/bin/npm: No such file or directory ``` I can always run: ``` curl https://npmjs.org/install.sh | sh ``` but that seems to indicate that npm is actually NOT included in node. When they say they are included do they just mean the code is in the same repo, but the binaries are still different? Final question I have /usr/bin/node as well as /usr/bin/nodejs can i delete one of these? im not sure when/where i picked up a second copy.

Original source