service: Always include start and stop in service command completions.
Not all services are in /etc/init.d files (such as systemd ones) from which command completions can be parsed from.
This commit is contained in:
parent
472b5bb958
commit
ccb8c91803
@ -22,7 +22,7 @@ _service()
|
||||
sysvdir=/etc/rc.d/init.d || sysvdir=/etc/init.d
|
||||
COMPREPLY=( $( compgen -W '`sed -e "y/|/ /" \
|
||||
-ne "s/^.*\(U\|msg_u\)sage.*{\(.*\)}.*$/\2/p" \
|
||||
$sysvdir/${prev##*/} 2>/dev/null`' -- "$cur" ) )
|
||||
$sysvdir/${prev##*/} 2>/dev/null` start stop' -- "$cur" ) )
|
||||
fi
|
||||
|
||||
return 0
|
||||
|
Loading…
x
Reference in New Issue
Block a user