fixed COMPREPLY's in _iwconfig

This commit is contained in:
David Paleino 2008-06-23 11:16:05 +02:00
parent 448df27e05
commit c4fb179ed7
2 changed files with 5 additions and 4 deletions

View File

@ -1104,7 +1104,7 @@ _iwconfig()
essid)
COMPREPLY=( $( compgen -W 'on off any' -- $cur ) )
if [ -n "${COMP_IWLIST_SCAN:-}" ]; then
COMPREPLY=( "${COMPREPLY[@]:-}" \
COMPREPLY=( "${COMPREPLY[@]}" \
$( iwlist ${COMP_WORDS[1]} scan | \
awk -F '"' '/ESSID/ {print $2}' | \
grep "^$cur" ))
@ -1131,7 +1131,7 @@ _iwconfig()
ap)
COMPREPLY=( $( compgen -W 'on off any' -- $cur ) )
if [ -n "${COMP_IWLIST_SCAN:-}" ]; then
COMPREPLY=( "${COMPREPLY[@]:-}" \
COMPREPLY=( "${COMPREPLY[@]}" \
$( iwlist ${COMP_WORDS[1]} scan | \
awk -F ': ' '/Address/ {print $2}' | \
grep "^$cur" ) )
@ -1140,7 +1140,7 @@ _iwconfig()
;;
rate)
COMPREPLY=( $( compgen -W 'auto fixed' -- $cur ) )
COMPREPLY=( "${COMPREPLY[@]:-}" \
COMPREPLY=( "${COMPREPLY[@]}" \
$( iwlist ${COMP_WORDS[1]} rate | \
awk '/^[[:space:]]*[0-9]/ {print $1"M"}' | \
grep "^$cur" ) )

3
debian/changelog vendored
View File

@ -4,8 +4,9 @@ bash-completion (20080617.4) UNRELEASED; urgency=low
- added quote(), quote_readline(), dequote() helper functions.
- fixed _get_cword()
- refactored _filedir using quote_readline()
- fixed COMPREPLY's in _iwconfig
-- David Paleino <d.paleino@gmail.com> Mon, 23 Jun 2008 11:12:28 +0200
-- David Paleino <d.paleino@gmail.com> Mon, 23 Jun 2008 11:15:48 +0200
bash-completion (20080617.3) unstable; urgency=low