0

how to I can update Node js to Node v4.2.6 - Node LTS version from terminal of linux?

i have this error in terminal ubuntu:

ERR: Your Node.js version is v4.2.6. Please update to the latest Node 6 LTS version (or latest Node).
simon
  • 621
  • 1
  • 6
  • 14
  • Possible duplicate of [Upgrading Node.js to latest version](https://stackoverflow.com/questions/10075990/upgrading-node-js-to-latest-version) – AJD- Jun 30 '17 at 17:08

1 Answers1

2

This is of course a duplicate question but... You should use n to achieve node version in an easier way:

  • https://github.com/tj/n to read instructions.

  • But is easy as follow:

    $ sudo npm i -g n

  • Then install a node version as follow:

    $ sudo n 8.1.3

  • Or simply:

    $ sudo n latest

jesusgn90
  • 563
  • 2
  • 12