Skip to content

Publish versioned Docker/Homebrew artifacts for RCs, not just stable - #52

Merged
naliyi merged 1 commit into
mainfrom
docker-homebrew-rc-publish
Sep 18, 2026
Merged

naliyi merged 1 commit into
mainfrom
docker-homebrew-rc-publish

Conversation

@naliyi

@naliyi naliyi commented Sep 18, 2026

Copy link
Copy Markdown
Contributor

Summary

  • v0.5.0-rc.1 shipped with no Docker image and no Homebrew formula at all, because skip_push/skip_upload: auto applied to entries whose image_templates mixed the version tag together with latest/the stable formula -- an RC skipped everything, not just the "latest" surfaces.
  • Splits each per-arch dockers: entry and docker_manifests: entry into a "-versioned" half (always pushed) and a "-latest" half (skip_push: auto, stable only), so an RC now gets its own ghcr.io/ohstr/ncli:X.Y.Z-rc.N tag while :latest still only ever tracks a real stable release.
  • Adds a second ncli-rc Homebrew formula with the inverse skip_upload (uploads only for a prerelease tag), since the free-tier brews: pipe has no versioned-formula feature (that's cask-only/Pro). brew install/upgrade ncli still only ever resolves to stable; brew install ohstr/tap/ncli-rc gets the latest RC. Both formulas declare conflicts_with the other since they install the same ncli binary name.

Verification

  • goreleaser check on the rewritten config: same pre-existing deprecation warnings as the unmodified file on main (legacy dockers/brews pipes, already a known tradeoff documented in the file), no new errors.
  • Verified the templated skip_upload inversion directly against Go's text/template semantics: renders false (upload) for a non-empty Prerelease, true (skip) for an empty one -- exactly inverted from the main formula's auto.

Test plan

  • CI green on this PR
  • Next actual release (RC or stable) confirms the split behaves as expected in a real GoReleaser run

Previously skip_push: auto / skip_upload: auto applied to entries whose
image_templates mixed the version tag with latest, so a prerelease
(v0.5.0-rc.1) published nothing at all -- not even a version-tagged
Docker image. v0.5.0-rc.1 shipped that way.

Splits each per-arch docker entry and the docker_manifests entry into a
"-versioned" half (always pushed) and a "-latest" half (skip_push: auto,
stable releases only), so an RC now gets its own ghcr.io/ohstr/ncli:X.Y.Z-rc.N
tag while :latest still only ever tracks stable.

brews has no free-tier equivalent of the cask pipe's versioned-formula
support, so RCs get a second, separate `ncli-rc` formula instead: its
skip_upload is the inverse of the main `ncli` formula's (upload only
on a prerelease tag), and each formula declares conflicts_with the
other since both install a binary named `ncli`.
@naliyi
naliyi merged commit 4d24d43 into main Sep 18, 2026
4 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