Skip to content

Select the requested tag when publishing a stable release - #140

Merged
drudge merged 1 commit into
mainfrom
codex/pin-release-tag
Sep 6, 2026
Merged

Select the requested tag when publishing a stable release#140
drudge merged 1 commit into
mainfrom
codex/pin-release-tag

Conversation

@drudge

@drudge drudge commented Sep 6, 2026

Copy link
Copy Markdown
Owner

When a stable release and its last candidate point to the same commit, GoReleaser's default tag ordering can select the candidate even though the workflow verified the stable tag. The 1.0.0 publish attempt selected rc.24 and stopped when it reached the immutable candidate release.

Pass the workflow's resolved tag as GORELEASER_CURRENT_TAG during publication, using GoReleaser's documented override for multiple tags on one commit. This also lets the workflow safely retry the existing 1.0.0 tag without moving it or modifying the published candidate release.

Validation: reproduced with the exact GoReleaser 2.18.0 binary in a disposable repository with annotated v1.0.0 and v1.0.0-rc.24 tags on the same commit. Without the override, metadata selected rc.24; with it, metadata and the built executable report 1.0.0. git diff --check passes. No application or palette changes.

Reference: https://goreleaser.com/resources/cookbooks/set-a-custom-git-tag/

@drudge
drudge merged commit 2093825 into main Sep 6, 2026
2 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.

1 participant