Repository navigation
fix(release): use postflight_steps for Homebrew cask hook - #207
Merged
Merged
Conversation
Homebrew deprecated the `postflight` block in casks, so installing claws prints a deprecation warning. Switch the GoReleaser cask hook to `install_steps` (GoReleaser v2.19+), which generates `postflight_steps` with the `run` step DSL, and require GoReleaser ^v2.19 in CI. Co-Authored-By: Claude Opus 5.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
Installing the cask (
brew install --cask clawscli/tap/claws) prints:Reported in clawscli/homebrew-tap#1. The cask is generated by GoReleaser, so the fix belongs here.
.goreleaser.yaml: switchhooks.post.install(deprecated in GoReleaser v2.19) tohooks.post.install_steps, using the step DSL (on_macos/run/{{ .StagedPath }}).release.yml: require GoReleaser^v2.19(>=2.19.0 <3.0.0) soinstall_stepsis always supported.Generated cask:
Verification
goreleaser checkandgoreleaser release --snapshotwith v2.19.0: cask generated as above.install_steps:on_macos,run, and{{staged_path}}are supported, and the steps sandbox allows writes under the Caskroom (which includesstaged_path).brew installof the generated cask. This will take effect on the next release.🤖 Generated with Claude Code