Versioning NPM packages
A lot of people don't know that it's super simple to version npm packages. And have used things like `gulp-bump` or other needless packages. The `npm version` command makes this simple.
A lot of people don't know that it's super simple to version npm packages. And have used things like gulp-bump
or other needless packages. man npm-version
shows us that it's as simple as:
npm version major
npm version minor
npm version patch
Following semver, it will update the package.json
file automatically and apply a git
tag with the version. This allows you to duplicate annotated package versions on github with what's been released in your packages through npm deploy
. Couldn't be simpler!