Skip to content

Add release-tag workflow for tagging from CI - #71

Merged
tmoonlight merged 1 commit into
masterfrom
claude/github-version-tag-release-l2h68z
Sep 23, 2026
Merged

tmoonlight merged 1 commit into
masterfrom
claude/github-version-tag-release-l2h68z

Conversation

@tmoonlight

Copy link
Copy Markdown
Owner

Adds .github/workflows/release-tag.yml, a manually dispatched workflow that creates a release tag from CI. Use it in environments that can't push tags directly.

Inputs: version (without the leading v) and an optional sha (defaults to the master head).

The workflow checks these before it tags:

  • the version string is valid
  • the target commit exists and is on master
  • CMakeLists.txt at that commit declares the same version
  • v<version> does not already exist

If they all pass, it pushes an annotated v<version> tag using the workflow token. Tags pushed with that token don't fire push workflows, so it then runs gh workflow run package.yml --ref v<version>. package.yml keys its release path off github.ref, so the result matches a manually pushed tag. The release gate is unchanged: publication still waits for the tagged commit's test.yml push run on master.

I ran the tag script locally against a scratch bare remote. It rejected an invalid version, a version mismatch, an off-master commit, an unknown SHA and an existing tag, and it created an annotated tag on the given commit. CLAUDE.md gets a short note on the workflow.

First use: tag 1a581cf5 (#70 merge, version 0.9.25) as v0.9.25.

🤖 Generated with Claude Code

https://claude.ai/code/session_01GWrEYUASNh3BnMktJQ7F9J


Generated by Claude Code

Environments that cannot push tags directly can dispatch this workflow to
tag a master commit (after checking the CMake version and that the tag is
new) and start package.yml on the tag ref.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01GWrEYUASNh3BnMktJQ7F9J
@tmoonlight
tmoonlight merged commit d91816e into master Sep 23, 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