Skip to content

ci(release): a Run workflow button that cuts the tag from stack.yaml - #21

Merged
ruehowl merged 1 commit into
mainfrom
claude/release-run-workflow
Oct 27, 2026
Merged

ruehowl merged 1 commit into
mainfrom
claude/release-run-workflow

Conversation

@ruehowl

@ruehowl ruehowl commented Oct 27, 2026

Copy link
Copy Markdown
Contributor

Why

release.yml only ran when someone pushed a v* tag, so cutting a release needed someone who can push tags. 0.20.1 (#20, the turbo-package guard fix) is merged but unreleased for exactly that reason: the session that merged it gets HTTP 403 on a tag push. lumen already cuts its baseline tags this way, from a dispatched tag.yml.

What

release.yml gains a Run workflow button (workflow_dispatch, no inputs):

  • the version comes from metadata.version in stack.yaml, and the tag is v<version>;
  • the run creates the tag and the GitHub release on the commit it ran from (gh release create --target "$GITHUB_SHA"), then verifies, publishes and confirms the package exactly as a tag push does;
  • it refuses a ref other than main;
  • it refuses a version whose tag already points at another commit, which means stack.yaml wasn't bumped. A tag on the same commit is a re-run of the same release and carries on, matching how a tag push re-runs;
  • a concurrency: release group stops two releases from racing.

Tag pushes behave as before. The one change on that path is --target "$GITHUB_SHA", which is the commit the tag already points at.

README.md's release flow and docs/verification.md's release section describe both ways to start a release.

Checked

The version step's script, taken straight from the YAML, run on every path:

run result
dispatch on main, no tag yet ✓ RELEASE_TAG=v0.20.1
dispatch on another branch ✗ Run the release from main
dispatch, v0.20.1 already on another commit ✗ already points at 24895a3 … Bump metadata.version
dispatch re-run, tag on this commit ✓ carries on
tag push v0.20.1 matching stack.yaml ✓
tag push v0.20.2 not matching ✗

After merge

I'll run Release from main to cut v0.20.1 and publish ghcr.io/sourceplane/stack-tectonic:0.20.1.



Generated by Claude Code

release.yml ran only on a pushed v* tag, so a release needed someone
who can push tags. It now also runs from Actions -> Release -> Run
workflow: the version comes from stack.yaml on main, the run creates
the v<version> tag and the GitHub release on the commit it ran from
(gh release create --target), then verifies and publishes exactly as
a tag push does.

A dispatched run refuses a ref other than main, and refuses a version
whose tag already points at another commit (stack.yaml not bumped); a
tag on the same commit is a re-run and carries on. A concurrency group
keeps two releases from racing. Tag pushes behave as before.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01BfmHkwWeA1oPJGBNF3QSQH
@ruehowl
ruehowl marked this pull request as ready for review October 27, 2026 07:02
@ruehowl
ruehowl merged commit e62730c into main Oct 27, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants