Prerequisites
To install the latest stable release of sails with the command-line tool issue following command:
$ sudo npm install sails -g
Depending on your OS you might not need to use sudo.
sudo