Home / Uncategorized / Install Node JS on Ubuntu 16.04 using NVM

Install Node JS on Ubuntu 16.04 using NVM

To start off, we’ll need to get the software packages from our Ubuntu repositories that will allow us to build source packages. The nvm script will leverage these tools to build the necessary components:

sudo apt-get update
sudo apt-get install build-essential libssl-dev
curl -o- https://raw.githubusercontent.com/creationix/nvm/v0.33.11/install.sh | bash

It will install the software into a subdirectory of your home directory at ~/.nvm. It wilt will install the software into a subdirectory of your home directory at ~/.nvm. It will also add the necessary lines to your ~/.profile file to use the file.l also add the necessary lines to your ~/.profile file to use the file.

To gain access to the nvm functionality, you’ll need to log out and log back in again, or you can source the ~/.profile file so that your current session knows about the changes:

source ~/.profile

Now that you have nvm installed, you can install isolated Node.js versions.

To find out the versions of Node.js that are available for installation, you can type:

nvm ls-remote

nvm install 10.14.2
nvm use 10.14.2

About admins

Leave a Reply

Your email address will not be published. Required fields are marked *