| 1 |
#compdef rc-status |
| 2 |
|
| 3 |
_rc_runlevels() { |
| 4 |
_values runlevels $(rc-status "${opt_args[(i)-U|--user]}" --list) |
| 5 |
} |
| 6 |
|
| 7 |
_arguments -s \ |
| 8 |
'(-a --all)'{-a,--all}'[Show services from all run levels]' \ |
| 9 |
'(-c --crashed)'{-c,--crashed}'[Show crashed services]' \ |
| 10 |
'(-f --format)'{-f,--format}'[format status to be parsable (currently arg must be ini)]:format:(ini)' \ |
| 11 |
'(-i --in-state)'{-i,--in-state}'[Show services which are in this state]:state:(stopped started stopping starting inactive hotplugged failed scheduled crashed)' \ |
| 12 |
'(-l --list)'{-l,--list}'[Show list of run levels]' \ |
| 13 |
'(-m --manual)'{-m,--manual}'[Show manually started services]' \ |
| 14 |
'(-r --runlevel)'{-r,--runlevel}'[Show the name of the current runlevel]' \ |
| 15 |
'(-s --servicelist)'{-s,--servicelist}'[Show service list]' \ |
| 16 |
'(-S --supervised)'{-S,--supervised}'[show supervised services]' \ |
| 17 |
'(-u --unused)'{-u,--unused}'[Show services not assigned to any runlevel]' \ |
| 18 |
'(- :)'{-h,--help}'[Display this help output]' \ |
| 19 |
'(-C --nocolor)'{-C,--nocolor}'[Disable color output]' \ |
| 20 |
'(- :)'{-V,--version}'[Display software version]' \ |
| 21 |
'(-v --verbose)'{-v,--verbose}'[Run verbosely]' \ |
| 22 |
'(-q --quiet)'{-q,--quiet}'[Run quietly (repeat to suppress errors)]' \ |
| 23 |
'(-U --user)'{-U,--user}'[Run in user mode]' \ |
| 24 |
'1:runlevels:_rc_runlevels' |
| 25 |
|
| 26 |
# vim: set et sw=2 ts=2 ft=zsh: |