bundle: extend cleanup coverage#22395
Open
MikeMcQuaid wants to merge 1 commit into
Open
Conversation
- let `cleanup --all` opt in to all supported types - support cleanup for `mas` and `krew` - show readable cleanup item names for extensions
Contributor
There was a problem hiding this comment.
Pull request overview
This PR extends brew bundle cleanup to support a broader set of dependency types and improves the readability of cleanup output for extension-based package types. It also adds/updates tests to cover the new behavior and option surface.
Changes:
- Add
brew bundle cleanup --allto opt into cleaning all supported dependency types (formulae, casks, taps, and supported extensions). - Add cleanup support for the
mas(Mac App Store) andkrewextensions. - Improve dry-run output to display human-friendly item names for extension cleanup entries.
Reviewed changes
Copilot reviewed 8 out of 8 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| Library/Homebrew/bundle/subcommand/cleanup.rb | Adds --all handling and prints readable extension cleanup item names in dry-run output. |
| Library/Homebrew/bundle/extensions/extension.rb | Introduces a default cleanup_item_name hook for extensions to customize display names. |
| Library/Homebrew/bundle/extensions/mac_app_store.rb | Implements cleanup_heading, cleanup item encoding/decoding, item naming, and uninstall logic for mas. |
| Library/Homebrew/bundle/extensions/krew.rb | Enables cleanup support for krew via cleanup_heading and an uninstall implementation. |
| Library/Homebrew/test/cmd/bundle/cleanup_subcommand_spec.rb | Adds a unit test ensuring cleanup --all selects all supported cleanup types. |
| Library/Homebrew/test/cmd/bundle_spec.rb | Verifies cleanup --all option help text. |
| Library/Homebrew/test/bundle/mac_app_store_spec.rb | Adds tests for mas cleanup item selection, naming, and uninstall behavior. |
| Library/Homebrew/test/bundle/krew_spec.rb | Adds tests for krew cleanup item selection and uninstall behavior. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
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.
cleanup --allopt in to all supported typesmasandkrewbrew lgtm(style, typechecking and tests) with your changes locally?OpenAI Codex 5.5 xhigh with local review and testing.