about summary refs log tree commit diff
path: root/Completion/Unix/Command/_pgrep
diff options
context:
space:
mode:
authorOliver Kiddle <opk@zsh.org>2015-05-11 12:11:25 +0200
committerOliver Kiddle <opk@zsh.org>2015-05-11 12:11:32 +0200
commit5b7e50dcd0786a47e180499c9a7a28cffcd73c1d (patch)
tree087dd99331442b8b24825477262f723216d22f98 /Completion/Unix/Command/_pgrep
parentd756f4eafd5d9f5fb3125d88d6a8b703b3ab6078 (diff)
downloadzsh-5b7e50dcd0786a47e180499c9a7a28cffcd73c1d.tar.gz
zsh-5b7e50dcd0786a47e180499c9a7a28cffcd73c1d.tar.xz
zsh-5b7e50dcd0786a47e180499c9a7a28cffcd73c1d.zip
35049: allow jail completion to include jid 0 for the host and to
complete jails by any parameter
Diffstat (limited to 'Completion/Unix/Command/_pgrep')
-rw-r--r--Completion/Unix/Command/_pgrep12
1 files changed, 1 insertions, 11 deletions
diff --git a/Completion/Unix/Command/_pgrep b/Completion/Unix/Command/_pgrep
index 3af55a379..d3dcd1812 100644
--- a/Completion/Unix/Command/_pgrep
+++ b/Completion/Unix/Command/_pgrep
@@ -8,7 +8,7 @@ arguments=('-P[parent process id]:parent process id:->ppid'
      '-F[match only in process in pidfile]:files:_files'
      '-g[match only in process group ids]:group:->pgid'
      '-G[match only real group id]:group:_groups'
-     '-j[match only in processes inside jails]:jail id:->jid'
+     '-j[match only in processes inside jails]:jail id:_sequence _jails -0 -o jid'
      '-J[match only in project ids]:project id:->projid'
      '-M[extract the name list from the specified core]:files:_files'
      '-N[extract the name list from the specified system]:files:_files'
@@ -93,16 +93,6 @@ case $state in
     _wanted sid expl 'session id' compadd -S ',' -q -F used $sid
     ;;
 
-  (jid)
-    compset -P '*,'
-
-    local -a used jid
-    used=(${(s:,:)IPREFIX})
-    jid=(${(uon)$(ps -ax -o jid=)})
-
-    _wanted jid expl 'jail id' compadd -S ',' -q -F used $jid
-    ;;
-
   (ppid)
     compset -P '*,'