bundle: add WinGet support#22397
Merged
Merged
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
This PR adds brew bundle support for managing Windows packages via WinGet when running under WSL, including dumping installed WinGet packages into a Brewfile and installing/cleaning them up in a non-interactive way (with an elevation retry flow).
Changes:
- Introduces a new Bundle extension (
winget) that can detect, dump, install, and clean up WinGet packages (WSL-only). - Updates platform-specific skipping behavior so
wingetentries are skipped (with warnings) on macOS and on non-WSL Linux. - Adds comprehensive RSpec coverage for the new extension and updates docs/examples to include
wingetusage.
Reviewed changes
Copilot reviewed 11 out of 11 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
| Library/Homebrew/test/support/helper/subcommand.rb | Adds winget?/no_winget? predicates to the test subcommand args helper. |
| Library/Homebrew/test/bundle/winget_spec.rb | New spec suite covering WinGet check/dump/install/cleanup and path handling. |
| Library/Homebrew/test/bundle/skipper_spec.rb | Adds skipper coverage for winget across macOS/Linux/WSL. |
| Library/Homebrew/test/bundle/dumper_spec.rb | Ensures dump ordering and selection includes the new winget extension. |
| Library/Homebrew/test/bundle/dsl_spec.rb | Verifies Brewfile DSL parsing and option validation for winget. |
| Library/Homebrew/extend/os/mac/bundle/skipper.rb | Skips winget entries on macOS with a WSL requirement warning. |
| Library/Homebrew/extend/os/linux/bundle/skipper.rb | Skips winget entries on Linux when not running under WSL. |
| Library/Homebrew/bundle/skipper.rb | Adds :winget to the env-based skip list. |
| Library/Homebrew/bundle/extensions/winget.rb | Implements the new WinGet Bundle extension (dump/install/cleanup, WSL path helpers, elevation retry). |
| Library/Homebrew/bundle/extensions.rb | Adds winget to the legacy dump ordering list (at the end). |
| docs/Brew-Bundle-and-Brewfile.md | Documents WinGet support and provides Brewfile examples. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
4d6fc41 to
7c47c9e
Compare
- make Windows package state manageable from WSL - use `winget` and `msstore` sources with stable IDs - keep installer UI disabled while allowing UAC retry - dump non-internal packages with readable names
7c47c9e to
fd9847d
Compare
p-linnane
approved these changes
May 24, 2026
Member
p-linnane
left a comment
There was a problem hiding this comment.
Love to see bundle continue to become more versatile!
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.
wingetandmsstoresources with stable IDsbrew lgtm(style, typechecking and tests) with your changes locally?OpenAI Codex 5.5 xhigh with local review and testing.