Support (very, very) basic brew-rs installs#21840
Merged
MikeMcQuaid merged 1 commit intomainfrom Mar 27, 2026
Merged
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
Adds an initial “bottle-only” install implementation to the Rust brew-rs frontend so it can complete an end-to-end fetch → pour → link flow for very simple formulae, while delegating anything more complex back to Ruby.
Changes:
- Implement basic
brew-rs install <formula>: resolve bottle, fetch it, pour it into the Cellar, remove receipt/SBOM files, then call back into Rubybrew link. - Extend Rust formula/bottle metadata parsing to include additional install-related fields (deps,
post_install_defined, service/keg-only/caveats) and propagate bottlecellar. - Add CLI tests covering a successful basic bottle install + link, and delegation when
post_installis defined.
Reviewed changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated 2 comments.
| File | Description |
|---|---|
Library/Homebrew/rust/brew-rs/tests/cli.rs |
Adds coverage for the new Rust install flow and delegation behavior. |
Library/Homebrew/rust/brew-rs/src/commands/install.rs |
Introduces a minimal Rust install pipeline (resolve/fetch/pour/link) with delegation gating. |
Library/Homebrew/rust/brew-rs/src/commands/fetch.rs |
Exposes/extends bottle+formula metadata so install can reuse Rust resolution results and check install constraints. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
32a050c to
3c382dd
Compare
- keep simple bottle-only `brew install` on the Rust path so the experimental frontend can prove out end-to-end pours before mirroring the full Ruby installer - reuse the Rust bottle resolution and fetch flow, then call back into `brew link` after the pour while leaving `TODO` markers for relocation, dependencies, `post_install`, tabs, SBOMs and the remaining installer stages - normalize API cellar values like `:any_skip_relocation` because the live bottle metadata uses that spelling and otherwise delegated real bottles back to Ruby
3c382dd to
5c1d023
Compare
p-linnane
approved these changes
Mar 27, 2026
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.
brew installon the Rust path so the experimental frontend can prove out end-to-end pours before mirroring the full Ruby installerbrew linkafter the pour while leavingTODOmarkers for relocation, dependencies,post_install, tabs, SBOMs and the remaining installer stages:any_skip_relocationbecause the live bottle metadata uses that spelling and otherwise delegated real bottles back to Rubybrew lgtm(style, typechecking and tests) with your changes locally?OpenAI Codex used locally and tested/reviewed locally.