fix(release): compute previous stable tag for GoReleaser changelog - #117
Merged
Conversation
GoReleaser defaults to the nearest reachable git tag when building release notes. Once beta tags started being cut directly from HEAD ahead of a stable release, that nearest tag became the beta tag instead of the prior stable release, and the only commit after it (the "chore: release" bump) is excluded by changelog filters — leaving v1.60.0's GitHub release notes empty. Explicitly pass --previous-tag pointing at the latest non-prerelease tag so the changelog always diffs against the last stable release. Co-Authored-By: Claude Sonnet 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.
Summary
v1.60.0's GitHub release notes shipped empty (just the GoReleaser footer) because GoReleaser's default "previous tag" resolution picked upv1.60.0-beta.2instead ofv1.59.0, and the only commit in between (chore: release v1.60.0) is excluded bychangelog.filters..github/workflows/release.ymlthat computes the latest non-prerelease tag (excluding the tag currently being released) and passes it to GoReleaser via--previous-tag, so the changelog always diffs against the last stable release regardless of intervening beta tags.Closes #116
Test plan
v1.60.0, the new lookup logic (git for-each-refsorted by creatordate, filtered to tags without-, excluding self) resolves tov1.59.0— matching the range that produced the correct localCHANGELOG.mdentry.🤖 Generated with Claude Code