Update based on comments (without a mutex...)
This commit is contained in:
parent
ac4c9d1324
commit
9395ec4d30
13
bin/brew
13
bin/brew
@ -48,19 +48,14 @@ if [[ -n "$HOMEBREW_ENV_FILTERING" ]]
|
||||
then
|
||||
PATH="/usr/bin:/bin:/usr/sbin:/sbin"
|
||||
|
||||
export HOMEBREW_BREW_FILE
|
||||
export HOMEBREW_PREFIX
|
||||
export HOMEBREW_REPOSITORY
|
||||
export HOMEBREW_LIBRARY
|
||||
# export HOMEBREW_BREW_FILE
|
||||
# export HOMEBREW_PREFIX
|
||||
# export HOMEBREW_REPOSITORY
|
||||
# export HOMEBREW_LIBRARY
|
||||
|
||||
execution_env=()
|
||||
for key in HOME SHELL PATH TERM LOGNAME USER "${!HOMEBREW_@}"
|
||||
do
|
||||
# ugly, unfortunate consequence of lack of `export -p NAME` in bash's export
|
||||
|
||||
# The following failed to find non exported vars on Bash 3.2.48
|
||||
[[ "$(declare -p "$key" 2>/dev/null)" =~ ^declare\ -[^\ ]*x[^\ ]*\ ]] || continue
|
||||
|
||||
execution_env+=( "${key}=${!key}" )
|
||||
done
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user