Skip to content

ci(release): make the manual trigger work and guard the version - #4

Merged
codeminute-the-dev merged 1 commit into
masterfrom
claude/ghidra-engine-improvements-aaab5u
Aug 23, 2026
Merged

codeminute-the-dev merged 1 commit into
masterfrom
claude/ghidra-engine-improvements-aaab5u

Conversation

@codeminute-the-dev

Copy link
Copy Markdown
Collaborator

Makes release.yml releasable from the GitHub UI (or by me) without a terminal, and stops a version mismatch from shipping.

The dispatch button didn't work

workflow_dispatch declares a version input, but no job ever reads it — every field came from github.ref_name. A manual run from master would have published a release named "RawView master" and tried to create a master tag.

A new version job resolves the tag once for both triggers:

  • tag push → uses the tag it already carries
  • manual run → takes the input (1.3.1 or v1.3.1, both fine) and action-gh-release creates the tag at that commit via tag_name

prerelease now derives from the resolved tag rather than the raw ref, so v1.4.0-rc.1 is still flagged correctly.

Version guard

The same job refuses to build when the tag doesn't match pyproject.toml. Every packaging script derives its filenames from there — build-deb.sh:30, build-appimage.sh:28, build-rpm.sh, scripts/build-msi.ps1:16. Tagging v1.3.1 while pyproject.toml still said 1.3.0 would publish rawview_1.3.0_amd64.deb and RawView-1.3.0.msi inside a release called v1.3.1.

It now fails in seconds, before the two runners spend ~15 minutes each downloading Ghidra 12.0.4 and building packages.

Verified

I extracted the resolve step's shell and ran it against the real pyproject.toml (1.3.1):

event input result
dispatch 1.3.1 accept → v1.3.1, prerelease=false
dispatch v1.3.1 accept → v1.3.1
push v1.3.1 accept → v1.3.1
push v1.4.0-rc.1 accept → prerelease=true
dispatch 1.3.0 reject — mismatch vs pyproject 1.3.1
dispatch master reject — bad format
dispatch 1.3 reject — bad format

YAML parses and the job graph is version → {linux, windows} → release.

After this merges

v1.3.1 can be released without a terminal: Actions → Release → Run workflow → version 1.3.1. Or tell me and I'll trigger it.


Generated by Claude Code

workflow_dispatch declared a `version` input that no job ever read. Every field came
from github.ref_name, so a manual run from master would have published a release named
"RawView master" and tried to create a `master` tag. The button was unusable.

A `version` job now resolves the tag once for both triggers: a tag push carries it,
a manual run passes it in (with or without the leading v) and action-gh-release
creates the tag at that commit via tag_name.

The same job refuses to build when the tag does not match pyproject.toml. Every
packaging script derives its filenames from there - build-deb.sh:30,
build-appimage.sh:28, build-rpm.sh, scripts/build-msi.ps1:16 - so tagging v1.3.1 while
pyproject.toml still said 1.3.0 would have published rawview_1.3.0_amd64.deb and
RawView-1.3.0.msi inside a release called v1.3.1. It now fails in seconds, before the
two runners spend ~15 minutes downloading Ghidra and building packages.

Prerelease is derived from the resolved tag rather than the raw ref, so a
v1.4.0-rc.1 tag is still flagged prerelease.
@codeminute-the-dev
codeminute-the-dev merged commit a1972e1 into master Aug 23, 2026
1 of 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