chore(ci): tag-driven release workflow#5
Merged
Conversation
Replace push-to-main auto-bump release with a two-workflow setup: version-bump.yml (manual, computes + commits + tags) and release.yml (tag-driven publish, idempotent, validates tag matches package.json, preserves workspace:* substitution at publish time only). Co-Authored-By: Claude Opus 4.6 (1M context) <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.
Summary
version-bumpworkflow.release.ymlnow triggers only onv*tags, validates the tag matches semver, verifies all three publishablepackage.jsons match the tag, and publishes idempotently in dependency order (core->cli->mcp).version-bump.ymlis the new manual entrypoint: pickpatch/minor/major/prerelease, it commits the bump and pushes the tag, which triggersrelease.yml.workspace:*-> concrete-version substitution is preserved as a publish-time-only transformation (never committed)..github/workflows/README.mddocumenting how to cut a release, emergency manual path, rollback story, and what not to do.Before / after
Before: every push to
main-> auto-bump patch -> publish -> commitrelease: vX.Y.Zback to main -> tag. Typo fix in README cut a release. No way to do minor/major. Race conditions on commit-back.Before: manual flow only. From the Actions tab run Version Bump, choose level. The workflow bumps all three packages, commits
chore: bump version to vX.Y.Z, pushes tagvX.Y.Z. Tag push triggersrelease.ymlwhich runs build/test, asserts tag matches package versions, rewritesworkspace:*->^X.Y.Zin memory, publishes idempotently (npm viewskip for already-published versions), and creates a GitHub Release with--generate-notes(which then triggersbinaries.yml).Safety properties
v\d+\.\d+\.\d+(-.*)?.core/cli/mcppackage.jsondisagrees with the tag.workspace:*post-rewrite assertion: greps the three manifests forworkspace:*and fails the run if any remain.npm view <pkg>@<ver>per package; re-running on the same tag is safe.version-bump.ymlaborts if the computed tag already exists.How to cut v1.0.0 (recommendation)
level=major. That will move0.1.14->1.0.0, commit, tag, and trigger publish.release.ymlfinish (it will publish@sowdb/core@1.0.0, then@sowdb/cli@1.0.0, then@sowdb/mcp@1.0.0, then create the GitHub Release).binaries.ymlwill then build and attach the standalone CLI binaries.level=prerelease(default tagrc) to ship0.1.15-rc.0, smoke test from npm, then runlevel=majorfor the real1.0.0.Test plan
level=prereleaseto validate end-to-end on a throwaway RC.@sowdb/corelisted as^X.Y.Z(notworkspace:*) in the publishedcli/mcpmanifests.binaries.ymlran on the resulting GitHub Release.release.ymlon the same tag and confirm it skips everything (idempotent).🤖 Generated with Claude Code