Node configuration.
Update NPM version with the following command
npm update -g npm
Download NVM (Node Version Manager), which will help you to use the correct version of NodeJS
curl -o- https://raw.githubusercontent.com/creationix/nvm/v0.30.1/install.sh | bash
In order to activate the NVM install, run the following command:
. ~/.nvm/nvm.sh
To use a specific NodeJS version, you need to have nvm install the correct version and then you need to tell nvm to right version:
nvm install 4.2.4 && nvm use 4.2.4
If you get permission errors, try this, which will correct permission errors:
sudo chown -R $(whoami) $(npm config get prefix)/{lib/node_modules,bin,share}