1.0.0 • Published 9 years ago
dvcn v1.0.0
Dependency version change notify (dvcn)
A small utility which notifies if there has been a change in the dependencies of the project ( bower and npm).
- A new dependency added in the latest commit in the project.
- The version of an existing dependency has been changed.
- Any existing dependency removed
Obsolete dependencies cause errors in the project. So instead of debugging the issue at the wrong end, developers have to be notified to take a "bower update" or "npm update".
Installation
// depending on your task runner
bower install dvcn
npm install dvcn
Usage
In your build , check before starting dev server :
var dvcn = require('dvcn');
var hasChanged = dvcn({
bower : true,
package : false
});
if(hasChanged.bower) {
console.error("Run bower update")
}
if(hasChanged.package) {
console.error("Run npm update")
}
Directory structure for your project:
Home | : package.json : bower.json : node_modules : src
(i.e. package.json and bower.json are the root of the project. )
Contribution
Contributions and improvements are welcome!
Footnote
Thanks to Mr Lalit Tanwar for his motivation and help.
1.0.0
9 years ago