bin/brew: include alias in sudo check
This commit is contained in:
parent
e12e1a5d5d
commit
e3011dfe91
2
bin/brew
2
bin/brew
@ -140,7 +140,7 @@ HOMEBREW_BASH_COMMAND="$HOMEBREW_LIBRARY/Homebrew/cmd/$1.sh"
|
|||||||
if [[ "$(id -u)" = "0" && "$(stat -f%u "$HOMEBREW_BREW_FILE")" != "0" ]]
|
if [[ "$(id -u)" = "0" && "$(stat -f%u "$HOMEBREW_BREW_FILE")" != "0" ]]
|
||||||
then
|
then
|
||||||
case "$HOMEBREW_COMMAND" in
|
case "$HOMEBREW_COMMAND" in
|
||||||
install|reinstall|postinstall|link|pin|unpin|update|update-bash|upgrade|create|migrate|tap|switch)
|
instal|install|reinstall|postinstall|ln|link|pin|unpin|update|update-bash|upgrade|create|migrate|tap|switch)
|
||||||
odie <<EOS
|
odie <<EOS
|
||||||
Cowardly refusing to 'sudo brew $HOMEBREW_COMMAND'
|
Cowardly refusing to 'sudo brew $HOMEBREW_COMMAND'
|
||||||
You can use brew with sudo, but only if the brew executable is owned by root.
|
You can use brew with sudo, but only if the brew executable is owned by root.
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user