Semver release versioning: commit-driven bumps, back-patches, flavors#12
Merged
Conversation
… flavors Replace the decimal "tenths" counter (which rolled v0.9 -> v1.0 and could never express v0.10) with real semver vMAJOR.MINOR.PATCH. - Bump level is driven by [bump:patch|minor|major] markers in the commit messages since the last release; an unmarked commit defaults to minor on master and patch on release/* maintenance branches. A new commit-convention.yml PR check rejects malformed markers before merge. - "latest" is the highest CLEAN tag reachable from HEAD (git tag --merged), so release/* branches cut independent back-patches: a fix on release/v0.6 (forked at v0.6.0) publishes v0.6.1 even while master is on v0.8. - Optional flavor builds: workflow_dispatch flavor=<name> publishes an unordered variant vX.Y.Z-<flavor> (prerelease) off the latest clean release, without bumping the line. Scans match only clean vX.Y[.Z] tags so a flavor tag never becomes a baseline. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
The marker lint extracted every [bump:...] bracket, so a commit or PR title that *describes* the markers (e.g. [bump:patch|minor|major]) tripped it. Restrict candidates to single tokens [bump:<word>]; pipes/stars/spaces are notation, not a malformed marker. Single-level typos like [bump:pacth] are still rejected. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Scanning full commit bodies meant any commit documenting the markers tripped the lint (a body mentioning an example marker, or notation, read as malformed). Read only the subject line (and PR title) in both the lint and the release bump computation, so bodies stay free prose. Markers belong on the subject, like skip-ci tags. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Replaces the decimal "tenths" version counter with real semver, and adds a commit-message convention, maintenance-branch back-patching, and optional flavor variants.
Why
The old scheme treated the version as tenths:
v0.9bumped tov1.0and could never producev0.10. It also conflated the major/minor split with no semantic meaning.What changed
vendor.ymlvMAJOR.MINOR.PATCH. The bump is the highest level any commit since the last release asks for:[bump:major]→ major,[bump:minor]→ minor,[bump:patch]→ patchmaster, patch onrelease/*(so a hotfix can't collide with a mainline minor tag)latest/prevtagusegit tag --merged HEADand match only cleanvX.Y[.Z]tags → enables independent back-patches onrelease/*branches and keeps flavored tags out of ordering.release/*added to the push trigger; concurrency is per-ref so a back-patch doesn't queue behind a master build.flavordispatch input publishes an unordered variantvX.Y.Z-<flavor>(marked prerelease) off the latest clean release, no version bump. (Label only for now — producing different binaries per flavor is follow-up build-args work.)commit-convention.yml(new) — PR check that rejects malformed[bump:*]markers (e.g.[bump:pacth]) before merge, so a typo can't silently mis-version a release. Never false-positives on[skip ci]/ markdown links.README.md— documents the scheme, the commit convention, back-patching, and flavors.All bump/lint/flavor logic was validated against a local simulation (rollover, branch defaults, typo rejection, flavor concat, prerelease detection).
Follow-up after merge
markersa required status check onmaster(and arelease/*ruleset) — can only be required once the check has run at least once, i.e. after this merges.