summaryrefslogtreecommitdiff
path: root/Completion/Zsh/Command/_kill
diff options
context:
space:
mode:
authorAxel Beckert <abe@deuxchevaux.org>2014-08-26 00:48:18 +0200
committerAxel Beckert <abe@deuxchevaux.org>2014-08-26 00:48:18 +0200
commita55d381f745d669c0ef9bdf0a4ce78a045ff3070 (patch)
tree31c741d92f2077f241835005b8cfd1db251445f6 /Completion/Zsh/Command/_kill
parent478d6c1db2ad16ea6b3cb6010cf083f2513494cf (diff)
parentcc69eef1cd835cd8d3f33960e9f616c894e7ae4f (diff)
downloadzsh-a55d381f745d669c0ef9bdf0a4ce78a045ff3070.tar.gz
zsh-a55d381f745d669c0ef9bdf0a4ce78a045ff3070.zip
Merge branch 'upstream' into debian
Diffstat (limited to 'Completion/Zsh/Command/_kill')
-rw-r--r--Completion/Zsh/Command/_kill6
1 files changed, 5 insertions, 1 deletions
diff --git a/Completion/Zsh/Command/_kill b/Completion/Zsh/Command/_kill
index 5e52a99de..b9dfde3f0 100644
--- a/Completion/Zsh/Command/_kill
+++ b/Completion/Zsh/Command/_kill
@@ -1,6 +1,7 @@
#compdef kill
local curcontext="$curcontext" line state ret=1
+typeset -A opt_args
_arguments -C \
'(-s -l 1)-n[specify signal number]:signal number' \
@@ -10,9 +11,12 @@ _arguments -C \
'*:processes:->processes' && ret=0
if [[ -n "$state" ]]; then
+ local pgrp='process-groups:: _wanted '
+ [[ -n "$opt_args[(i)-[ns]]${${(@)line:#--}}" && -prefix - ]] && pgrp+='-x '
+ pgrp+="process-groups expl 'process-group' compadd - 0"
_alternative \
'processes:: _pids' \
- 'jobs:: _jobs -t' && ret=0
+ 'jobs:: _jobs -t' $pgrp && ret=0
fi
return ret