install nvm and upgrade to latest node version

https://www.codementor.io/mercurial/how-to-install-node-js-on-macos-sierra-mphz41ekk