Thursday, July 20, 2017

upgrading npm

so trying https://davidwalsh.name/nvm

nvm ls
No command 'nvm' found, did you mean:
 Command 'n-m' from package 'python-networkmanager' (universe)
 Command 'kvm' from package 'qemu-kvm' (main)
 Command 'nvme' from package 'nvme-cli' (universe)
 Command 'pvm' from package 'pvm' (universe)
 Command 'nvi' from package 'nvi' (universe)
 Command 'vm' from package 'mgetty-voice' (universe)
 Command 'nam' from package 'nam' (universe)
 Command 'npm' from package 'npm' (universe)
 Command 'nim' from package 'nim' (universe)
 Command 'nm' from package 'binutils' (main)
 Command 'nm' from package 'binutils-multiarch' (main)
 Command 'lvm' from package 'lvm2' (main)
nvm: command not found

how to upgrade nodejs
google top link https://tecadmin.net/upgrade-nodejs-via-npm/ good link thanks google and thanks rahul

sudo npm cache clean -f
[sudo] password for :
npm WARN using --force I sure hope you know what you are doing.
sudo npm install -g n
/usr/local/bin/n -> /usr/local/lib/node_modules/n/bin/n
/usr/local/lib
└── n@2.1.8
 sudo n stable

     install : node-v8.2.0
       mkdir : /usr/local/n/versions/node/8.2.0
       fetch : https://nodejs.org/dist/v8.2.0/node-v8.2.0-linux-x64.tar.gz
   installed : v8.2.0
admin:~$ sudo ln -sf /usr/local/n/versions/node/8.2.0/bin/node /usr/bin/node

 node -v
v8.2.0


No comments:

Post a Comment