I need to upgrade the node.js version in my ubuntu machine but after doing it also its also showing the old version. I am explaining my command below.
curl -sL https://deb.nodesource.com/setup_9.x | sudo -E bash -
sudo apt-get install -y nodejs
Previously my version was v6.9.1
. I run the above command in terminal to upgrade the latest version but after successfully installing its still showing v6.9.1
when I am doing node -v
in my terminal. Here I need to upgrade to the latest version.
apt-get update
beforeapt-get install -y nodejs
?