I have a module called 'sails-mongo' and I want to update it to the newest version using the following command:
npm update sails-mongo --save
I also tried uninstall then install again. I tried sails-mongo@latest
and sails-mongo@beta
.
Problem: The current version (master) on GitHub the package.json (https://github.com/balderdashy/sails-mongo/blob/master/package.json) file has:
"dependencies": {
"async": "~0.2.9",
"lodash": "~2.4.1",
"mongodb": "1.4.2",
"waterline-errors": "~0.10.0"
},
And in the one being updated
"dependencies": {
"async": "0.2.10",
"underscore": "1.5.2",
"underscore.string": "2.3.3",
"mongodb": "~1.3.23"
},
The only way I get the master branch is using the command npm install git+https://github.com/balderdashy/sails-mongo
Why doesn't sails-mongo@latest
install the master branch?
repository
key inpackage.json
just identifies a repository which shows on the NPM page. – Sworpackage.json
. NPM stores each of these almost like Github does. When you run NPM install <package> it will always install the latest version, but if you specify the package inpackage.json
you can add which version you'd like to install. – Swor