mirror of
git://git.code.sf.net/p/zsh/code
synced 2025-09-03 22:32:12 +02:00
users/18498: observe add-space style in _expand_alias so suffix can be disabled
This commit is contained in:
parent
079540cc78
commit
7c31413278
2 changed files with 6 additions and 2 deletions
|
@ -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
|
||||
|
||||
|
|
|
@ -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
|
||||
|
|
Loading…
Reference in a new issue