fix(colored-man-pages): quote array expansion in colored function

Unquoted $environment expansion causes a 'bad pattern' error when the
GLOB_SUBST option is set, because zsh then treats the ANSI escape
sequences in LESS_TERMCAP_* values (e.g. ESC[00m) as glob patterns.
This commit is contained in:
Adam Spiers 2026-02-22 16:45:05 +00:00
commit 77d0c6afa4

View file

@ -43,7 +43,7 @@ function colored() {
environment+=( PATH="${__colored_man_pages_dir}:$PATH" )
fi
command env $environment "$@"
command env "${environment[@]}" "$@"
}
# Colorize man and dman/debman (from debian-goodies)