Skip to content

Instantly share code, notes, and snippets.

@traumverloren
Created May 9, 2023 19:29
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save traumverloren/7b1140e6c438988df755d047e1e98a7b to your computer and use it in GitHub Desktop.
Save traumverloren/7b1140e6c438988df755d047e1e98a7b to your computer and use it in GitHub Desktop.
# update system
$ sudo apt update && sudo apt upgrade
# uninstall old node (v10?)
$ sudo apt remove nodejs npm -y
# install nvm
$ curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.39.2/install.sh | bash
# use 'unofficial builds' in nvm
$ echo "export NVM_NODEJS_ORG_MIRROR=https://unofficial-builds.nodejs.org/download/release" >> ~/.bashrc
# reload bashrc
$ source ~/.bashrc
# install latest LTS
$ nvm install --lts
$ nvm use --lts
# verify versions
$ node -v
$ npm -v
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment