diff options
author | spreiter <36988897+spreiter@users.noreply.github.com> | 2020-10-29 11:54:29 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-10-29 11:54:29 +0100 |
commit | 47d30784c53ed3159fb317d4a1a1cedb105aa278 (patch) | |
tree | 7acd8cb721bc037e5124596aa2c3c503e8b16f21 /plugins/colorize/colorize.plugin.zsh | |
parent | 63922b5ec435d04ea31ee33138061f1d812beefe (diff) | |
download | zsh-47d30784c53ed3159fb317d4a1a1cedb105aa278.tar.gz zsh-47d30784c53ed3159fb317d4a1a1cedb105aa278.tar.bz2 zsh-47d30784c53ed3159fb317d4a1a1cedb105aa278.zip |
colorize: add compatibility for zsh < 5.1 (#9400)
The direct assignment of a local array is not possible in older ZSH version, as used by RHEL/CentOS 7.
Diffstat (limited to 'plugins/colorize/colorize.plugin.zsh')
-rw-r--r-- | plugins/colorize/colorize.plugin.zsh | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/plugins/colorize/colorize.plugin.zsh b/plugins/colorize/colorize.plugin.zsh index 80b69190f..cb5ac36f5 100644 --- a/plugins/colorize/colorize.plugin.zsh +++ b/plugins/colorize/colorize.plugin.zsh @@ -6,7 +6,8 @@ alias cless="colorize_less" ZSH_COLORIZE_PLUGIN_PATH=$0:A colorize_check_requirements() { - local available_tools=("chroma" "pygmentize") + local -a available_tools + available_tools=("chroma" "pygmentize") if [ -z "$ZSH_COLORIZE_TOOL" ]; then if (( $+commands[pygmentize] )); then |