Improve service(8) completion, also look for "msg_usage" (thanks to Elan Ruusamäe <glen@delfi.ee>)

This commit is contained in:
David Paleino 2009-09-17 22:24:21 +02:00
parent f13ea4968b
commit 3a69bd3e93
2 changed files with 2 additions and 1 deletions

View File

@ -38,6 +38,7 @@ bash-completion (1.x)
* Fixed obvious brokenness (typos) in contrib/mdadm * Fixed obvious brokenness (typos) in contrib/mdadm
* Patches from PLD Linux (thanks to Elan Ruusamäe): * Patches from PLD Linux (thanks to Elan Ruusamäe):
- avoid sed pipe as ps itself can omit the headers - avoid sed pipe as ps itself can omit the headers
- improve service(8) completion, also look for "msg_usage"
[ Ville Skyttä ] [ Ville Skyttä ]
* Split yum completion to contrib/_yum (no longer installed by default, the * Split yum completion to contrib/_yum (no longer installed by default, the

View File

@ -655,7 +655,7 @@ _service()
_services _services
else else
COMPREPLY=( $( compgen -W '`sed -ne "y/|/ /; \ COMPREPLY=( $( compgen -W '`sed -ne "y/|/ /; \
s/^.*Usage.*{\(.*\)}.*$/\1/p" \ s/^.*\(U\|msg_u\)sage.*{\(.*\)}.*$/\1/p" \
$sysvdir/${prev##*/} 2>/dev/null`' -- $cur ) ) $sysvdir/${prev##*/} 2>/dev/null`' -- $cur ) )
fi fi