Skip to content

ci: validate the goreleaser config on every PR - #117

Merged
sergiught merged 1 commit into
mainfrom
ci/validate-goreleaser-config
Aug 3, 2026
Merged

ci: validate the goreleaser config on every PR#117
sergiught merged 1 commit into
mainfrom
ci/validate-goreleaser-config

Conversation

@sergiught

Copy link
Copy Markdown
Owner

📝 Summary

Both deprecations fixed in #115 and #116 reached us the same way: as warnings printed at the top of every release run, where a green job means nobody reads the log. Nothing in CI validated .goreleaser.yaml, so the only feedback loop for release config was running a release.

This runs goreleaser check on every PR. It exits non-zero on deprecated options — that is the point, and precisely the signal we were missing.

Two supporting details:

  • Added as a step in the existing lint job, not a new job. Branch protection pins bare job names, so a new job would not be a required check until it is added there by hand; a step inside lint is enforced immediately.
  • GORELEASER_VERSION pinned in ci.yml to match release.yml, so the config is validated against the same goreleaser that publishes it. The renovate custom manager previously matched only release.yml, so a second pin would have silently drifted — managerFilePatterns now covers both workflows, keeping them in lockstep in a single renovate PR.

⛔ Merge last — CI on this PR is red until #115 and #116 land

This PR is the last in the sequence by necessity. main still carries both deprecations, so goreleaser check fails against it:

• dockers and docker_manifests are being phased out … replaced by dockers_v2
• DEPRECATED: brews should not be used anymore
⨯ check failed  error=1 out of 1 configuration file(s) have issues

That red check is the change working as intended, not a defect. Merge order: #114#115#116 → this.

Verified locally that the premise holds — with both migrations applied, the check passes:

$ git merge ci/migrate-dockers-v2      # onto ci/migrate-homebrew-casks
$ goreleaser check
  • checking                    path=.goreleaser.yaml
  • 1 configuration file(s) validated
EXIT=0

🏷 Type of change

  • 🐛 Bug fix (non-breaking)
  • ✨ Feature (non-breaking)
  • 💥 Breaking change (users must update)
  • ♻️ Refactor (no functional change)
  • 📚 Docs only
  • 🛠 Build / CI / tooling

🔗 Related issues

Completes the sequence started by #114 (attestations surviving a late-publisher failure), #115 (dockers_v2), #116 (homebrew_casks).

✅ How to verify

actionlint .github/workflows/ci.yml
goreleaser check                                   # fails on main, passes with #115 + #116
python3 -c "import json;json.load(open('.github/renovate.json'))"
grep -rn "GORELEASER_VERSION: " .github/workflows/  # both pins identical

📋 Checklist

  • 🧪 Tests added or updated where it makes sense — n/a, CI config; actionlint clean
  • 📖 Docs updated — n/a, no user-facing behaviour change
  • 🏷 PR title follows Conventional Commits
  • 🟢 make check passes locally — n/a, no Go code touched

The dockers/docker_manifests and brews deprecations both reached us as
warnings printed at the top of every release run, where a green job means
nobody reads the log. Nothing validated .goreleaser.yaml, so the only
feedback loop for release config was a release itself.

Run 'goreleaser check' in the existing lint job -- it exits non-zero on
deprecated options, which is exactly the signal we were missing. Adding
it as a step rather than a new job keeps it inside a check branch
protection already requires.

Pin GORELEASER_VERSION in ci.yml to match release.yml so the config is
validated against the same goreleaser that publishes it, and widen the
renovate custom manager to both workflows so the two pins cannot drift.
@sergiught
sergiught force-pushed the ci/validate-goreleaser-config branch from 4a014b6 to 7a08268 Compare August 3, 2026 09:54
@sergiught
sergiught merged commit 93bbfcc into main Aug 3, 2026
7 checks passed
@sergiught
sergiught deleted the ci/validate-goreleaser-config branch August 3, 2026 09:59
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