Simplify $UNAME checks.
This commit is contained in:
parent
60b2106b78
commit
d4e177a6ab
@ -929,7 +929,7 @@ _expand()
|
||||
|
||||
# This function completes on process IDs.
|
||||
# AIX and Solaris ps prefers X/Open syntax.
|
||||
[[ $UNAME == SunOS || $UNAME == AIX ]] &&
|
||||
[[ $UNAME == @(SunOS|AIX) ]] &&
|
||||
_pids()
|
||||
{
|
||||
COMPREPLY=( $( compgen -W '$( command ps -efo pid | sed 1d )' -- "$cur" ))
|
||||
@ -941,7 +941,7 @@ _pids()
|
||||
|
||||
# This function completes on process group IDs.
|
||||
# AIX and SunOS prefer X/Open, all else should be BSD.
|
||||
[[ $UNAME == SunOS || $UNAME == AIX ]] &&
|
||||
[[ $UNAME == @(SunOS|AIX) ]] &&
|
||||
_pgids()
|
||||
{
|
||||
COMPREPLY=( $( compgen -W '$( command ps -efo pgid | sed 1d )' -- "$cur" ))
|
||||
@ -953,7 +953,7 @@ _pgids()
|
||||
|
||||
# This function completes on process names.
|
||||
# AIX and SunOS prefer X/Open, all else should be BSD.
|
||||
[[ $UNAME == SunOS || $UNAME == AIX ]] &&
|
||||
[[ $UNAME == @(SunOS|AIX) ]] &&
|
||||
_pnames()
|
||||
{
|
||||
COMPREPLY=( $( compgen -X '<defunct>' -W '$( command ps -efo comm | \
|
||||
|
@ -1,7 +1,6 @@
|
||||
# man(1) completion
|
||||
|
||||
[[ $USERLAND == GNU || $UNAME == Darwin || $UNAME == FreeBSD || \
|
||||
$UNAME == SunOS || $UNAME == Cygwin || $UNAME == OpenBSD ]] &&
|
||||
[[ $USERLAND == GNU || $UNAME == @(Darwin|FreeBSD|SunOS|Cygwin|OpenBSD) ]] &&
|
||||
_man()
|
||||
{
|
||||
local cur prev words cword
|
||||
|
Loading…
x
Reference in New Issue
Block a user