Skip to content

fix(release): realign tracking refs after token-URL pushes - #669

Merged
brianjfox merged 1 commit into
mainfrom
fix/release-tap-tracking-ref
Aug 14, 2026
Merged

fix(release): realign tracking refs after token-URL pushes#669
brianjfox merged 1 commit into
mainfrom
fix/release-tap-tracking-ref

Conversation

@brianjfox

Copy link
Copy Markdown
Owner

Summary

Cutting 2.1.3, the release run died mid-pipeline: brew's auto-update rebased the tap onto its remote and conflicted on Formula/gnash.rb. Root cause: git_push pushes through an x-access-token URL, which never updates origin's remote-tracking refs, so after a release the tap (and main repo) permanently look out of date to any subsequent git pull --rebase — including the one brew update runs on taps.

This adds a git fetch -q origin after every token-URL push in git_push, keeping the tracking refs aligned with what was just pushed. Failure of the fetch is non-fatal (|| true) — it's housekeeping, not part of the release.

Testing

  • bash -n scripts/release.sh passes.
  • The equivalent manual git fetch origin in the tap after the 2.1.3 release brought main...origin/main back in sync, which is exactly the state this keeps automatically.

🤖 Generated with Claude Code

A push through the x-access-token URL does not update origin's
remote-tracking refs, so the tap later looks out of date and
`brew update` rebases it onto a remote that already contains the
pushed commits, conflicting on Formula/gnash.rb (as happened cutting
2.1.3). Fetch origin after such a push to realign.
@brianjfox
brianjfox merged commit a021614 into main Aug 14, 2026
1 check passed
@brianjfox
brianjfox deleted the fix/release-tap-tracking-ref branch August 14, 2026 12:25
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