Skip to content

mac_brew_pkg: add optional name arg to homebrew_prefix - #70068

Open
cdalvaro wants to merge 7 commits into
saltstack:3008.xfrom
cdalvaro:feature/mac_brew_pkg/homebrew_prefix
Open

mac_brew_pkg: add optional name arg to homebrew_prefix#70068
cdalvaro wants to merge 7 commits into
saltstack:3008.xfrom
cdalvaro:feature/mac_brew_pkg/homebrew_prefix

Conversation

@cdalvaro

@cdalvaro cdalvaro commented Aug 16, 2026

Copy link
Copy Markdown
Contributor

What does this PR do?

Rename the existing homebrew_prefix() to the private _homebrew_prefix() and expose a new public homebrew_prefix(name=None) that, when name is given, resolves the prefix for that specific formula via brew --prefix <name> instead of only the global Homebrew prefix.

New Behavior

You can now ask homebrew_prefix for the prefix of the given name:

salt '*' pkg.homebrew_prefix 'vim'

Merge requirements satisfied?

Commits signed with GPG?

Yes

@cdalvaro
cdalvaro requested a review from a team as a code owner August 16, 2026 18:46
@cdalvaro
cdalvaro force-pushed the feature/mac_brew_pkg/homebrew_prefix branch from b866dd2 to ecef49f Compare August 16, 2026 19:11
@cdalvaro
cdalvaro force-pushed the feature/mac_brew_pkg/homebrew_prefix branch from ecef49f to 5ddaf5a Compare August 16, 2026 19:13

@twangboy twangboy left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Let's make this against the 3008.x branch.

@twangboy twangboy added the test:full Run the full test suite label Aug 18, 2026
@twangboy twangboy added this to the Argon v3008.3 milestone Aug 18, 2026
@cdalvaro

Copy link
Copy Markdown
Contributor Author

Let's make this against the 3008.x branch.

F**k I always do the same mistake 😅

Comment thread salt/modules/mac_brew_pkg.py
Comment thread salt/modules/mac_brew_pkg.py Outdated
Comment thread salt/modules/mac_brew_pkg.py Outdated
Comment thread salt/modules/mac_brew_pkg.py Outdated
Comment thread salt/modules/mac_brew_pkg.py Outdated
Comment thread salt/states/pkg.py Outdated
Comment thread salt/states/pkg.py Outdated
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

test:full Run the full test suite

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants