Repository navigation
info: show install paths and PATH shadowing with --verbose - #24168
Merged
Merged
Conversation
Contributor
There was a problem hiding this comment.
Copilot review overview
🔵 Needs a closer look
Moderate issues remain around keg selection, duplicate PATH scans, and directory ordering.
Review effort: Lite
Findings: None
What changed in this PR
Updates verbose brew info output to show installation paths and PATH-shadowed executables.
Changes:
- Adds formula
Prefix:and per-kegCellar:paths. - Groups shadowed executables under
Binaries. - Updates related info and caveat tests.
| File | Summary |
|---|---|
Library/Homebrew/test/cmd/info_spec.rb |
Tests verbose paths and binary output. |
Library/Homebrew/test/caveats_spec.rb |
Tests grouped shadowing behavior. |
Library/Homebrew/cmd/info.rb |
Renders paths and verbose binary details; needs opt-linked keg selection and caching improvements. |
Library/Homebrew/caveats.rb |
Formats shadowing output; grouped directories need deterministic sorting. |
💡 Add a code-review agent skill for context-aware, tailored reviews. Learn more in the docs.
MikeMcQuaid
reviewed
Oct 5, 2026
MikeMcQuaid
left a comment
Member
There was a problem hiding this comment.
One tiny nit, otherwise looks good!
HaraldNordgren
force-pushed
the
info-verbose-keg-paths
branch
5 times, most recently
from
October 5, 2026 19:32
95de35e to
368c821
Compare
MikeMcQuaid
reviewed
Oct 6, 2026
MikeMcQuaid
left a comment
Member
There was a problem hiding this comment.
Thanks, almost there, was ready to approve but noticed one more thing.
HaraldNordgren
force-pushed
the
info-verbose-keg-paths
branch
from
October 6, 2026 09:05
368c821 to
7e03d8a
Compare
- The installed versions section dropped each keg's Cellar path, so `brew info` no longer showed where a formula is installed. - With `--verbose`, show the `Cellar:` path of every installed keg.
- The PATH shadowing caveat repeated the full shadowing path on every line, so group shadowed executables under a header naming the shadowing directory, in compact columns. - With `--verbose`, `brew info` already lists executables in the `Binaries` section, so show the shadowing there instead of in the caveats and drop shadowed executables from the main list. - `brew install` and `brew info` without `--verbose` still show it as a caveat.
HaraldNordgren
force-pushed
the
info-verbose-keg-paths
branch
from
October 6, 2026 09:15
7e03d8a to
c8d2c65
Compare
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.
It was hard for me to actually find the Homebrew paths to run binaries that are shadowed on my
PATH. This partly reverses #22241 and #22130.With
--verbose,brew infonow shows theCellar:path of each keg, and lists shadowed executables in theBinariessection, grouped by shadowing directory, instead of as a caveat. Without--verbose, the shadowing warning is no longer shown.brew benchmarkresults.brewcommands to reproduce the bug?brew lgtm(style, typechecking and tests) locally?I used Claude Code (Claude Opus 5.5) to write the code, tests and this description.