Reputation: 29436
I've installed Sails.js version 0.9.13
globally on my Mac which runs fine, but I'm trying to fiddle with the 0.10.0-rc4
locally in a folder.
Running sudo npm install sails@beta
seems to work fine; my node_modules/package.json says "version": "0.10.0-rc4"
But when I run sails new testProject
in that folder, the generated testProject/package.json says "sails": "0.9.13"
.
I know that I could just change the testProject/package.json to "version": "0.10.0-rc4"
and then npm install
but that doesn't work.
What am I doing wrong? How could I fix this?
Upvotes: 3
Views: 3288
Reputation: 890
I recommend using a virtual environment like nave. It will help you not to disturb your existing installations.
Sequence would go something like this:
npm install nave -g
nave use <envname> stable
$npm install sails@beta -g
Upvotes: 1
Reputation: 9025
Basically, you can just run
./node_modules/sails/bin/sails.js new testProject
instead of sails new testProject
once you have installed rc4 in some 'parent' folder.
Upvotes: 2