blob: c1f01ad17e95a933ad567838fe91a0a7eeb95be8 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
|
#compdef svcs
local -a cols
cols=(
ctid\:"contract id" desc\:"description" fmri\:"fmri"
inst\:"instance name" nsta\:"next state (abbr)" nstate\:"next state"
scope\:"scope name" svc\:"service name" sta\:"state (abbr)"
state\:"state" stime\:"start time" astate\:"name for current auxiliary state"
nrun\:"time of next scheduled run for periodic services"
lrun\:"time of the last run for periodic services"
)
_arguments -s \
'(-l -x -d -D)-a[list all instances]' \
'(-l -x -D -a -R)-d[list dependencies]' \
'(-l -x -d -a -R)-D[list dependents]' \
'(-l -x)-H[suppress header line]' \
'(-x -d -D -a -R -s)-l[print detailed status about services and instances]' \
'(-l -x)-o[display specific columns]:column:_values -s , "column" ${^cols/\:/[}\]' \
'(-l -x)-p[list processes]' \
'(-l -x -d -D)-R[list services with the given restarter]:instance FMRI:_svcs_fmri -i' \
'(-l -x)-s[sort by a column]:column:(($cols))' \
'(-l -x)-S[reverse sort by a column]:column:(($cols))' \
'-v[verbose columns]' \
'(-l)-x[display explanation for service states]' \
'(-l -x)-\?[print help]' \
'*:FMRI or pattern:_svcs_fmri -i'
|