How to install a specific version of Node on Ubuntu?

前端 未结 14 698
Happy的楠姐
Happy的楠姐 2020-12-07 12:52

I would like to install NodeJS version 0.8.18 on Ubuntu 12.04. I tried to install the newest version and then reverting to 0.8.18 by using nvm, but when I run m

14条回答
  •  自闭症患者
    2020-12-07 13:25

    To install a specific version of nodejs in Ubuntu you can use below commands, just specify and replace the version number, for example, node_12.x will fetch the latest of 12.

    curl https://deb.nodesource.com/gpgkey/nodesource.gpg.key | sudo apt-key add -
    sudo apt-add-repository "deb https://deb.nodesource.com/node_7.x $(lsb_release -sc) main"
    sudo apt-get update
    sudo apt-get install nodejs
    

提交回复
热议问题