Versioning

One version number, mirrored into three files, bumped by one command, published by one tag.

Single source of truth

FileHoldsWritten by
VERSIONPlain text version — the source of truthnpm run bump
manifest.json → versionWhat Chrome and the store readnpm run bump
package.json → versionTooling versionnpm run bump
CHANGELOG.mdHuman-readable historynpm run bump (skeleton), then you

Everyday commands

terminal
npm run bump patch     # 1.8.0 -> 1.8.1   fixes
npm run bump minor     # 1.8.0 -> 1.9.0   features
npm run bump major     # 1.8.0 -> 2.0.0   breaking changes

npm run verify         # all three version files must agree
npm run package        # build dist/freerammer-v<version>.zip

npm run bump rewrites only the version value inside manifest.json, so the store-generated formatting of the rest of the file stays byte-identical and the diff is a single line.

Release flow

  1. Make the change on main.
  2. Bump the version and fill in the new changelog section.
  3. Commit, tag and push:
terminal
git add -A
git commit -m "chore(release): v$(cat VERSION)"
git tag -a "v$(cat VERSION)" -m "v$(cat VERSION)"
git push origin main --follow-tags

The Release workflow then verifies the version files, checks that the tag matches VERSION, builds the zip and attaches it to a GitHub Release.

Guards

  • npm run verify fails if VERSION, manifest.json and package.json disagree.
  • On a clean, tagged commit it also fails if the tag does not match the version — that is what stops a mislabelled release.
  • While you are mid-bump the working tree is dirty, so the tag check steps aside instead of blocking you.
Current version: 1.9.1 — tagged v1.9.1, with the zip attached to the release.