Skip to content

Commit 485f1ab

Browse files
authored
Merge pull request #20053 from Homebrew/skip_zero_values
bin/brew: don't copy across zeroed env values.
2 parents 0b67caf + 916c25e commit 485f1ab

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

bin/brew

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -183,8 +183,8 @@ MANPAGE_VARS=(
183183
)
184184
for VAR in "${MANPAGE_VARS[@]}"
185185
do
186-
# Skip if variable value is empty.
187-
[[ -z "${!VAR:-}" ]] && continue
186+
# Skip if variable value is empty or set to 0.
187+
[[ -z "${!VAR:-}" || "${!VAR:-}" = "0" ]] && continue
188188

189189
VAR_NEW="HOMEBREW_${VAR}"
190190
# Skip if existing HOMEBREW_* variable is set.

0 commit comments

Comments
 (0)