getver
v1.0.2
Published
Get latest version number of a package from GitHub
Downloads
3
Readme
Install
npm install --save getver
Use
var getver = require('getver');
getver({
username: 'gswalden', // GitHub username of package owner
repo: 'getver' // GitHub repo name of package
}, function(err, version, pkg) {
console.log(err); // null or Error
console.log(version); // string containing version, i.e. "1.0.0"
console.log(pkg); // object containing entire package.json
});
Notes
This is a thin wrapper around github-get, and the options object will pass-through to that package. Therefore, you can include a token
property in order to access private repos.