Reputation: 5893
I installed nodejs
via nvm
on Ubuntu
server, and found issues with jenkins tasks. So I uninstalled nvm
, and reinstalled nodejs
by
sudo apt-get install curl
curl --silent --location https://deb.nodesource.com/setup_5.x | sudo bash -
sudo apt-get install nodejs
And now on my Ubuntu
server, the node
is back but npm
wasn't, how to reinstall npm
?
This is my command echo back: $ node -v 5.8.0
$ npm -v
-bash: /home/ubuntu/.nvm/versions/node/v5.8.0/bin/npm: No such file or directory
Upvotes: 1
Views: 722
Reputation: 5893
Finally I found the solution:
curl http://npmjs.org/install.sh | sudo sh
Upvotes: 1