Skip to content

fix: accept Homebrew-interpolated final tag in cask URL verify - #18

Merged
rianjs merged 1 commit into
mainfrom
fix/cask-verify-interpolated-tag
May 30, 2026
Merged

fix: accept Homebrew-interpolated final tag in cask URL verify#18
rianjs merged 1 commit into
mainfrom
fix/cask-verify-interpolated-tag

Conversation

@rianjs

@rianjs rianjs commented May 30, 2026

Copy link
Copy Markdown
Contributor

Problem

The Confirm published cask URL pins the final tag step in release.yml greps the dist cask for a literal /download/<final-tag>/. But release-preflight intentionally lets bare-v repos omit url.template, and goreleaser then renders the cask URL as Homebrew interpolation — /download/v#{version}/ — not a literal tag. Even url.template repos commit the interpolated form to the tap.

So the literal grep only passed for casks that happened to bake a literal tag. The first bare-v repo to reach the new step — slck v3.1.58 — failed, and its homebrew/chocolatey/winget/linux-packages fan-out was skipped, leaving every distro channel a release behind (stuck at 3.1.51) even though the GitHub release published all binaries.

Fix

Accept either:

  • the literal final tag — /download/v3.1.58/, or
  • the final-tag prefix plus #{version}/download/v#{version}/ (bare) or /download/jtk-v#{version}/ (prefixed).

Both forms genuinely pin the final tag; Homebrew resolves #{version} at install. The prefix is derived by stripping the version suffix from the final tag, so the guards are preserved:

  • a prefixed repo (jtk-v) emitting a bare v#{version} still fails (wrong-prefix guard);
  • a cask pinning an older version still fails (stale-tag guard).

Verified against all six cases (bare/prefixed × literal/interpolated, plus both guards).

The "Confirm published cask URL pins the final tag" step grepped the dist
cask for a literal /download/<final-tag>/. But release-preflight intentionally
lets bare-v repos omit url.template, and goreleaser then renders the cask URL
as Homebrew interpolation (/download/v#{version}/) — even url.template repos
commit the interpolated form to the tap. The literal grep only passed for
repos whose dist cask happened to bake a literal tag, so the first bare-v repo
to reach the step (slck v3.1.58) failed and its homebrew/chocolatey/winget/
linux fan-out was skipped, leaving every channel stuck a release behind.

Accept either the literal final tag or the final-tag prefix plus #{version}.
A prefixed repo (jtk-v) emitting a bare v#{version} still fails, and a cask
pinning an older version still fails — both guards preserved.
@rianjs
rianjs merged commit 699234b into main May 30, 2026
17 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