-
-
Notifications
You must be signed in to change notification settings - Fork 293
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Improve shelling out to brew
#1551
Conversation
37e8846
to
5cd67a1
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
HOMEBREW_BREW_FILE
is fairly common everywhere else (including in brew
) so I wonder if we can handle that constant better somehow.
Yea, I wonder if we should try replacing |
Good idea, will take a look at that. |
I already have a branch that does something like this, FYI. |
Allow the ability for a system administrator to use `HOMEBREW_BREW_WRAPPER` and `HOMEBREW_FORCE_BREW_WRAPPER` variables to enforce the usage of a particular `brew` command for non-trivial (e.g. `brew --prefix` is considered trivial, it doesn't need to write to the prefix) Homebrew commands. This also introduces a `HOMEBREW_ORIGINAL_BREW_FILE` variable for some internal usage; `HOMEBREW_BREW_FILE` was being used internally for both "how should we shell out to Homebrew" and "what should we use to check permissions on Homebrew". `HOMEBREW_ORIGINAL_BREW_FILE` is now used just for the latter case. Inspired by conversation in Homebrew/homebrew-bundle#1551 which suggested this was worth fixing in wider than just `brew bundle`.
Closing in favour of Homebrew/brew#19049 |
Add a `Bundle.brew` helper to DRY things up a bit.
5cd67a1
to
1310c69
Compare
Actually, repurposed the refactoring here to make it a no-op and just DRY things up a bit. |
Allow the ability for a system administrator to use `HOMEBREW_BREW_WRAPPER` and `HOMEBREW_FORCE_BREW_WRAPPER` variables to enforce the usage of a particular `brew` command for non-trivial (e.g. `brew --prefix` is considered trivial, it doesn't need to write to the prefix) Homebrew commands. This also introduces a `HOMEBREW_ORIGINAL_BREW_FILE` variable for some internal usage; `HOMEBREW_BREW_FILE` was being used internally for both "how should we shell out to Homebrew" and "what should we use to check permissions on Homebrew". `HOMEBREW_ORIGINAL_BREW_FILE` is now used just for the latter case. Inspired by conversation in Homebrew/homebrew-bundle#1551 which suggested this was worth fixing in wider than just `brew bundle`.
Add a
Bundle.brew
helper to DRY things up a bit.