diff options
-rw-r--r-- | ChangeLog | 3 | ||||
-rw-r--r-- | Completion/Base/Completer/_expand_alias | 5 |
2 files changed, 6 insertions, 2 deletions
diff --git a/ChangeLog b/ChangeLog index f9e7f1690..27b5e9a80 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,8 @@ 2014-02-24 Oliver Kiddle <opk@zsh.org> + * users/18498: Completion/Base/Completer/_expand_alias: observe + add-space style in _expand_alias so suffix can be disabled + * users/18485: Completion/Unix/Command/_git: add .. as an auto-removable suffix in git revision ranges diff --git a/Completion/Base/Completer/_expand_alias b/Completion/Base/Completer/_expand_alias index 8848e668d..8240e4162 100644 --- a/Completion/Base/Completer/_expand_alias +++ b/Completion/Base/Completer/_expand_alias @@ -1,7 +1,7 @@ #compdef -K _expand_alias complete-word \C-xa local word expl tmp pre sel what -local -a tmpa +local -a tmpa suf eval "$_comp_setup" @@ -58,7 +58,8 @@ if [[ -n $tmp ]]; then tmp="\\$tmp" fi fi - $pre _wanted aliases expl alias compadd -UQ -- ${tmp%%[[:blank:]]##} + zstyle -T ":completion:${curcontext}:" add-space || suf=( -S '' ) + $pre _wanted aliases expl alias compadd -UQ "$suf[@]" -- ${tmp%%[[:blank:]]##} elif (( $#pre )) && zstyle -t ":completion:${curcontext}:" complete; then $pre _aliases -s "$sel" -S '' else |