diff options
Diffstat (limited to 'Completion/Unix/Command/_service')
-rw-r--r-- | Completion/Unix/Command/_service | 20 |
1 files changed, 12 insertions, 8 deletions
diff --git a/Completion/Unix/Command/_service b/Completion/Unix/Command/_service index 50e8607bf..1216f57a8 100644 --- a/Completion/Unix/Command/_service +++ b/Completion/Unix/Command/_service @@ -5,24 +5,28 @@ # _sub_command happy # we are interested in init service only -local args ctx="${curcontext}argument-1:" +local args actions ctx="${curcontext}argument-1:" zstyle -T ":completion:${ctx}" tag-order && \ zstyle ":completion:${ctx}" tag-order init case $OSTYPE in + freebsd<11->.*) + args=( '-j+[perform actions in specified jail]:jail:_jails' ) + ;& freebsd*|dragonfly*) - args=( - '(-)-r[show the results of boot time rcorder]' - '(-)-R[restart all enabled local services]' + actions=( + '(*)-r[show the results of boot time rcorder]' + '(*)-R[restart all enabled local services]' ) ;& netbsd*) _arguments -s $args \ - '(-)-e[show services that are enabled]' \ - '(-)-l[list all scripts in /etc/rc.d and the local startup directory]' \ '(-e -R)-v[verbose]' \ - ':service name:_services' \ - '*::service argument:_init_d' + '*::service argument:_init_d' \ + + '(actions)' $actions \ + '(*)-e[show services that are enabled]' \ + '(*)-l[list all scripts in /etc/rc.d and the local startup directory]' \ + ':service name:_services' ;; *) _arguments -s \ |