verz is a simple CLI tool for bumping the version of your Node.js project, committing the change, and creating a Git tag — all in one go.
🤓 Fun fact: verz uses itself to manage its own versions.
Install verz globally or as a dev dependency:
# Using npm
npm install -D verz
# Using yarn
yarn add -D verz
# Using pnpm
pnpm add -D verzOr run it directly without installation using npx:
npx verz --<type>Run verz in the root of your project:
verz version --<type> [options]
# or simply
verz --<type> [options]<type> is the type of version bump (see semver)
Create a git tag for the current version without bumping:
verz tag [options]| Option | Description | Default |
|---|---|---|
--patch |
Bump the patch version (0.0.x) | false |
--minor |
Bump the minor version (0.x.0) | false |
--major |
Bump the major version (x.0.0) | false |
--prerelease [preid] |
Bump to prerelease version (e.g., 1.0.0 -> 1.0.1-rc.0). Optionally specify preid (alpha, beta, rc, etc.) | false |
--version <version> |
Set exact version (e.g., 1.2.3) | |
--commit.message |
Custom commit message. Use %v for version. |
chore: release %v |
-v, --verbose |
Enable verbose debug logging. | false |
--dry-run |
Run without writing files or committing. | false |
| Option | Description | Default |
|---|---|---|
-v, --verbose |
Enable verbose debug logging. | false |
--dry-run |
Run without creating the tag. | false |
You can configure verz using a configuration file. Create one of the following files in your project root:
verz.config.jsverz.config.mjsverz.config.json
The configuration file structure:
{
"commit": {
"message": "chore: version %v"
},
"tag": {
"name": "%v"
}
}Bump the patch version:
verz --patch
# or
verz version --patchBump to a prerelease version (defaults to 'rc' preid):
verz --prerelease
# or
verz version --prereleaseBump to a specific prerelease type:
verz --prerelease beta
# or
verz version --prerelease betaSet an exact version:
verz --version 2.0.0
# or
verz version --version 2.0.0Create a tag for the current version:
verz tagCreate a tag with verbose output:
verz tag --verboseBump the minor version with a custom commit message:
verz --minor --commit.message "release: bump to %v"Create a git tag for the current version without bumping:
verz --tag-onlyDry run (show what would happen without doing it):
verz --major --dry-runEnable verbose logging:
verz --patch -vRun without installing:
npx verz --patchMIT License