Skip to main content
Wright Websites

semver-gauge

check semver vs commits

CI gate that checks your version bump matches the changes since the last release (Conventional Commits: breaking/feat/fix) and that CHANGELOG.md has a real entry for the new version.

  • 20/week on npm
  • 2★
  • MIT
  • v1.1.1
  • Developer Tooling
npx semver-gauge

Read the full README on GitHub (opens in a new tab)View on npm (opens in a new tab)

semver-gauge

From the README

semver-gauge looks at the commits since your last release tag, works out the bump they need from Conventional Commits (feat → minor, fix/perf → patch, ! or a BREAKING CHANGE: footer → major) and compares that with the version in package.json. A breaking change shipped as a minor, a version that went backwards, a skipped version or a tag that already exists is reported with a severity and a concrete fix ("Bump to 2.0.0"). It also checks that CHANGELOG.md has a non-empty, correctly dated entry for the version, at the top.

semver-gauge --source changesets                 # .changeset/*.md decides the bump
semver-gauge --api dist/index.d.ts               # a removed/changed export needs a major bump
semver-gauge --workspaces --require-bump         # per-package versions in a monorepo

Related packages

Developer Tooling