Fix for aliases (from zsh-users)

http://www.zsh.org/mla/users/2011/msg00005.html
This commit is contained in:
Julien Nicoulaud 2011-01-05 11:28:24 +01:00
parent 77ff47dc27
commit a640bb8b96
1 changed files with 1 additions and 1 deletions

View File

@ -328,7 +328,7 @@ _zsh_highlight-zle-buffer() {
case $res in
*': reserved') style=$ZSH_HIGHLIGHT_STYLES[reserved-word];;
*': alias') style=$ZSH_HIGHLIGHT_STYLES[alias]
local aliased_command=${"$(alias $arg)"#*=}
local aliased_command="${"$(alias $arg)"#*=}"
if [[ ${${ZSH_HIGHLIGHT_TOKENS_FOLLOWED_BY_COMMANDS[(r)$aliased_command]:-}:+yes} = 'yes' && ${${ZSH_HIGHLIGHT_TOKENS_FOLLOWED_BY_COMMANDS[(r)$arg]:-}:+yes} != 'yes' ]]; then
ZSH_HIGHLIGHT_TOKENS_FOLLOWED_BY_COMMANDS+=($arg)
fi