Tells you the next semantic version for your local package
Install and use
Imagine a local package with current version 2.3.0 and a single semantic
fix(something): fix the login. This tools computes the next
version that should be used.
npm install -g next-vernext-vernext version should be 2.3.1
npm version 2.3.1
Incrementing version in package file
If there is a new version, you can update the version in the "package.json"
file and commit the change, including creating a tag, just like the
npm version <new version> does.
--go to the
Semantic version rules
A semantic version has form "major.minor.patch"
A typical semantic commit has message of the form "type(scope): message". Commits that do not follow this format are ignored when computing next version.
If there is a commit
fix(something): ... then new version should increment
the "patch" number. A commit
feat(something): ... will increment the
"minor" number. Finally, a commit with text "BREAKING" anywhere in the message
or the message body text will increment the "major" number.
When there are multiple numbers, the will be only the highest single digit increment. For example, these 4 commits will increment the "minor" number only.
fix(this): ... fix(that): ... feat(log): ... feat(server): ...
--goincrements the version in the current folder's
--version, -vshows the version of
- latest-version-or-tag is
used to fetch NPM tags and compare latest to the version in
Testing and development
Author: Gleb Bahmutov <firstname.lastname@example.org> © 2016
License: MIT - do anything with the code, but don't blame me if it does not work.
Support: if you find any problems with this module, email / tweet / open issue on Github
Copyright (c) 2016 Gleb Bahmutov <email@example.com>
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.