Skip to content

bundle: add WinGet support#22397

Merged
MikeMcQuaid merged 1 commit into
mainfrom
bundle-winget-wsl
May 24, 2026
Merged

bundle: add WinGet support#22397
MikeMcQuaid merged 1 commit into
mainfrom
bundle-winget-wsl

Conversation

@MikeMcQuaid
Copy link
Copy Markdown
Member

  • 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

  • Have you followed the guidelines in our Contributing document?
  • Have you checked to ensure there aren't other open Pull Requests for the same change?
  • Have you added an explanation of what your changes do and why you'd like us to include them? Performance claims (e.g. "this is faster") must include Hyperfine benchmarks.
  • Have you written new tests (excluding integration tests) for your changes? Here's an example.
  • Have you successfully run brew lgtm (style, typechecking and tests) with your changes locally?

  • AI was used to generate or assist with generating this PR.

OpenAI Codex 5.5 xhigh with local review and testing.


Copilot AI review requested due to automatic review settings May 23, 2026 17:56
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

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 winget entries 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 winget usage.

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.

Comment thread Library/Homebrew/bundle/extensions/winget.rb Outdated
Comment thread Library/Homebrew/bundle/extensions/winget.rb Outdated
@MikeMcQuaid MikeMcQuaid force-pushed the bundle-winget-wsl branch 3 times, most recently from 4d6fc41 to 7c47c9e Compare May 24, 2026 11:39
@MikeMcQuaid MikeMcQuaid enabled auto-merge May 24, 2026 11:40
- 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
Copy link
Copy Markdown
Member

@p-linnane p-linnane left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Love to see bundle continue to become more versatile!

@MikeMcQuaid MikeMcQuaid added this pull request to the merge queue May 24, 2026
Merged via the queue into main with commit 07cc7c5 May 24, 2026
36 checks passed
@MikeMcQuaid MikeMcQuaid deleted the bundle-winget-wsl branch May 24, 2026 15:27
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.

3 participants