[Bash-completion-commits] [SCM] bash-completion branch, master, updated. a4961d7edc260e41eaca91b8d2d32b5203995e18
Ville Skyttä
ville.skytta at iki.fi
Fri May 29 20:10:43 UTC 2009
The following commit has been merged in the master branch:
commit a4961d7edc260e41eaca91b8d2d32b5203995e18
Author: Ville Skyttä <ville.skytta at iki.fi>
Date: Fri May 29 23:10:35 2009 +0300
Test for Linux only once.
diff --git a/contrib/wireless-tools b/contrib/wireless-tools
index 797938a..1d3fb84 100644
--- a/contrib/wireless-tools
+++ b/contrib/wireless-tools
@@ -3,9 +3,10 @@
#
# bash completion for Linux wireless-tools
-# Linux iwconfig(8) completion
-#
-[ $UNAME = Linux ] && have iwconfig &&
+[ $UNAME = Linux ] &&
+{
+
+have iwconfig &&
_iwconfig()
{
local cur prev
@@ -109,9 +110,8 @@ _iwconfig()
} &&
complete -F _iwconfig iwconfig
-# Linux iwlist(8) completion
-#
-[ $UNAME = Linux ] && have iwlist &&
+
+have iwlist &&
_iwlist()
{
local cur prev
@@ -134,9 +134,8 @@ _iwlist()
} &&
complete -F _iwlist iwlist
-# Linux iwspy(8) completion
-#
-[ $UNAME = Linux ] && have iwspy &&
+
+have iwspy &&
_iwspy()
{
local cur
@@ -156,9 +155,8 @@ _iwspy()
} &&
complete -F _iwspy iwspy
-# Linux iwpriv(8) completion
-#
-[ $UNAME = Linux ] && have iwpriv &&
+
+have iwpriv &&
_iwpriv()
{
local cur prev
@@ -189,3 +187,5 @@ _iwpriv()
fi
} &&
complete -F _iwpriv iwpriv
+
+}
--
bash-completion
More information about the Bash-completion-commits
mailing list