ci(release): tag releases from merged release PRs in CI - #51
Merged
Merged
Conversation
Release tags are now immutable, so a tag pushed by hand on the wrong commit or version could never be taken back. Merging a release PR now triggers the workflow, which checks the commit is that PR's merge and the versions agree, builds, and only then creates the tag. This replaces `just push-tag` and `just push-zed-tag`. Co-Authored-By: Claude Opus 5.5 <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.
Why
Release tags (
v*,zed-v*) are now immutable via therelease-tags-immutableruleset, so a tag pushed by hand on the wrong commit or version can never be taken back. Tagging moves into CI, after the checks pass.What
release.ymlruns on pushes tomainthat touchpackages/css-var-kit/package.json(and onworkflow_dispatch, main only) instead of on tag pushes.verifyskips the run whenv<version>already exists, fails unless the commit is a mergedchore/release-<version>PR titledchore: release v<version>, and fails if the package versions disagree.tagpushes the tag with the deploy key only after every build passes, thenpublish/publish-vscode/github-releaserun in the same run (a tag pushed withGITHUB_TOKENdoes not trigger other workflows).release-zed.ymldoes the same forzed-v<version>(chore/release-zed-<version>,chore(zed): release v<version>), checkingCargo.tomlagainstextension.toml.just push-tag/just push-zed-tagare removed.Rulesets and secrets
The GitHub Actions app cannot be a ruleset bypass actor on a personal-account repository (the API rejects it with 422), so tags are created with a deploy key instead:
release-tags(creation): the only bypass actor is deploy keys; Repository Admin no longer bypasses it.RELEASE_TAG_KEYsecret of thereleaseenvironment (deployment branches:mainonly).tagjobs run in that environment and push the tag over SSH; the key is loaded into an ssh-agent that ends with the step.These are already in place.
Testing
commits/{sha}/pullsresponse: it matches after rewriting the branch and title to the release format, and fails as-is or with a mismatched version.🤖 Generated with Claude Code