Last active
September 19, 2016 13:19
-
-
Save dawn360/f866a66c151efcbb619d58d36fbb637e to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Use the NodeSource PPA. For details look at the installation instructions. First, choose the Node.js version you need and add the sources for it: | |
# for Node.js v4 | |
curl -sL https://deb.nodesource.com/setup_4.x | sudo -E bash - | |
# OR for Node.js v5 | |
curl -sL https://deb.nodesource.com/setup_5.x | sudo -E bash - | |
# OR for Node.js v6 | |
curl -sL https://deb.nodesource.com/setup_6.x | sudo -E bash - | |
Then install the Node.js package. | |
sudo apt-get install -y nodejs | |
P.S.: curl package must be installed on server for these code lines. | |
Upgrading | |
If you have nodejs already installed and want to update, then first remove current instalation and install it again using scripts above. | |
sudo apt-get purge nodejs npm | |
sudo npm install -g bower | |
sudo npm install -g grunt |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment