From af26cfb2851014e4e9aa5b23955ae2c78bb034f1 Mon Sep 17 00:00:00 2001 From: Ted Stern Date: Tue, 8 Dec 2009 19:43:00 +0200 Subject: [PATCH 01/10] Fix modules completion for "(default)" entries. --- CHANGES | 3 +++ contrib/modules | 2 +- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/CHANGES b/CHANGES index 0e7cc5e7..6ecf9a62 100644 --- a/CHANGES +++ b/CHANGES @@ -48,6 +48,9 @@ bash-completion (2.x) [ Freddy Vulto ] * Added _get_pword() helper function, thanks to Sung Pae (Alioth: #312030) + [ Ted Stern ] + * Fix modules completion for "(default)" entries. + -- David Paleino Sun, 11 Oct 2009 11:11:57 +0200 bash-completion (1.1) diff --git a/contrib/modules b/contrib/modules index 07b2d699..acc4fb6f 100644 --- a/contrib/modules +++ b/contrib/modules @@ -35,7 +35,7 @@ _module_avail () local modules="$( \ module avail 2>&1 | \ egrep -v '^(-|$)' | \ - xargs printf '%s\n' | sort )" + xargs printf '%s\n' | sed -e 's/(default)//g' | sort )" compgen -W "$modules" -- $1 } From 7248290e6e11fbde833029496d840b85149ac034 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ville=20Skytt=C3=A4?= Date: Tue, 8 Dec 2009 19:45:35 +0200 Subject: [PATCH 02/10] Deprecate modules completion, upstream modules >= 3.2.7 ships one. --- CHANGES | 1 + Makefile.am | 3 +-- contrib/{modules => _modules} | 3 +++ 3 files changed, 5 insertions(+), 2 deletions(-) rename contrib/{modules => _modules} (95%) diff --git a/CHANGES b/CHANGES index 6ecf9a62..438127d9 100644 --- a/CHANGES +++ b/CHANGES @@ -44,6 +44,7 @@ bash-completion (2.x) * sed usage portability fixes. * Fix leaking local variables from various completions. * Turn on -o filenames in _filedir on bash >= 4. + * Deprecate modules completion, upstream modules >= 3.2.7 ships one. [ Freddy Vulto ] * Added _get_pword() helper function, thanks to Sung Pae (Alioth: #312030) diff --git a/Makefile.am b/Makefile.am index d8d96150..50ffc53d 100644 --- a/Makefile.am +++ b/Makefile.am @@ -77,7 +77,6 @@ bashcomp_DATA = contrib/abook \ contrib/minicom \ contrib/mkinitrd \ contrib/mock \ - contrib/modules \ contrib/monodevelop \ contrib/mplayer \ contrib/msynctool \ @@ -152,4 +151,4 @@ profiledir = $(sysconfdir)/profile.d profile_DATA = bash_completion.sh EXTRA_DIST = CHANGES $(sysconf_DATA) $(bashcomp_DATA) $(profile_DATA) \ - contrib/_subversion contrib/_yum contrib/_yum-utils + contrib/_modules contrib/_subversion contrib/_yum contrib/_yum-utils diff --git a/contrib/modules b/contrib/_modules similarity index 95% rename from contrib/modules rename to contrib/_modules index acc4fb6f..33b367c3 100644 --- a/contrib/modules +++ b/contrib/_modules @@ -1,3 +1,6 @@ +# Use of this file is deprecated, upstream completion is available in +# modules >= 3.2.7, use that instead. +# # module completion by Ted Stern # # Completion for Environment Modules `module' alias. From 6e2b17c4e637f6cebe5a698c86258edfe86e8971 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ville=20Skytt=C3=A4?= Date: Tue, 8 Dec 2009 19:46:19 +0200 Subject: [PATCH 03/10] Add deprecation status/reason comments. --- contrib/_subversion | 3 +++ contrib/_yum | 3 +++ contrib/_yum-utils | 3 +++ 3 files changed, 9 insertions(+) diff --git a/contrib/_subversion b/contrib/_subversion index 5ed0a6ca..643ba0d6 100644 --- a/contrib/_subversion +++ b/contrib/_subversion @@ -1,3 +1,6 @@ +# Use of this file is deprecated. Upstream completion is available in +# subversion >= 0.12.0, use that instead. + # svn completion have svn && diff --git a/contrib/_yum b/contrib/_yum index d566d1fd..2c3f3eeb 100644 --- a/contrib/_yum +++ b/contrib/_yum @@ -1,3 +1,6 @@ +# Use of this file is deprecated. Upstream completion is available in +# yum >= 3.2.25, use that instead. + # yum(8) completion have yum && { diff --git a/contrib/_yum-utils b/contrib/_yum-utils index 4e2cf00b..1914ba0a 100644 --- a/contrib/_yum-utils +++ b/contrib/_yum-utils @@ -1,3 +1,6 @@ +# Use of this file is deprecated. Upstream completion is available in +# yum-utils >= 1.1.24, use that instead. + # bash completion for repomanage have repomanage && From 21d0f70cb03bd94660ea2f2585009fc81ca58d88 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ville=20Skytt=C3=A4?= Date: Wed, 9 Dec 2009 01:01:49 +0200 Subject: [PATCH 04/10] Use _shells in screen -s. --- contrib/screen | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/contrib/screen b/contrib/screen index 53a0fdeb..2118e2f5 100644 --- a/contrib/screen +++ b/contrib/screen @@ -43,8 +43,8 @@ _screen() return 0 ;; -s) - # shells - COMPREPLY=( $( grep ^${cur:-[^#]} /etc/shells ) ) + _shells + return 0 ;; -c) _filedir From 536a780c2ec7359988e28df79cf24e2b4badab49 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ville=20Skytt=C3=A4?= Date: Wed, 9 Dec 2009 01:06:47 +0200 Subject: [PATCH 05/10] Drop short options from screen completions where long(er) ones exist, add --help and --version. --- CHANGES | 2 +- contrib/screen | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/CHANGES b/CHANGES index 438127d9..1ae6a04d 100644 --- a/CHANGES +++ b/CHANGES @@ -24,7 +24,7 @@ bash-completion (2.x) * Apply pine completion to alpine too. * Remove many unnecessary short option completions where long ones exist. * Improve configure, cvs, gkrellm, lftp, mdadm, modprobe, mplayer, - mysqladmin, service, scp, ssh, and general hostname completions. + mysqladmin, screen, service, scp, ssh, and general hostname completions. * Add abook and wtf completion, based on work by Raphaël Droz. * Add jarsigner, k3b, lftpget, pack200 and unpack200 completions. * Don't overwrite other host completions when completing from multiple diff --git a/contrib/screen b/contrib/screen index 2118e2f5..253c9d52 100644 --- a/contrib/screen +++ b/contrib/screen @@ -53,9 +53,9 @@ _screen() esac if [[ "$cur" == -* ]]; then - COMPREPLY=( $( compgen -W '-a -A -c -d -D -e -f -fn -fa -h -i \ - -l -ln -ls -list -L -m -O -p -q -r -R -s -S -t -U -v \ - -wipe -x -X' -- "$cur" ) ) + COMPREPLY=( $( compgen -W '-a -A -c -d -D -e -f -fn -fa -h -i -ln \ + -list -L -m -O -p -q -r -R -s -S -t -U -v -wipe -x -X --help \ + --version' -- "$cur" ) ) fi } && complete -F _screen -o default screen From b4b4b37b9654ed47fd907a07f19148423c02c03c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ville=20Skytt=C3=A4?= Date: Wed, 9 Dec 2009 20:43:21 +0200 Subject: [PATCH 06/10] Fix version in upstream availability comment. --- contrib/_yum | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/contrib/_yum b/contrib/_yum index 2c3f3eeb..eac90144 100644 --- a/contrib/_yum +++ b/contrib/_yum @@ -1,5 +1,5 @@ # Use of this file is deprecated. Upstream completion is available in -# yum >= 3.2.25, use that instead. +# yum > 3.2.25, use that instead. # yum(8) completion From d68c8e508a5f3ed77a6a8e07b2abf69cc467302d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ville=20Skytt=C3=A4?= Date: Wed, 9 Dec 2009 20:55:45 +0200 Subject: [PATCH 07/10] Indentation fixes. --- contrib/update-alternatives | 76 ++++++++++++++++++------------------- 1 file changed, 38 insertions(+), 38 deletions(-) diff --git a/contrib/update-alternatives b/contrib/update-alternatives index a3438d54..6a3f541d 100644 --- a/contrib/update-alternatives +++ b/contrib/update-alternatives @@ -26,13 +26,13 @@ _update_alternatives() prev=${COMP_WORDS[COMP_CWORD-1]} case "$prev" in - --altdir|--admindir) - _filedir -d - return 0 - ;; - --help|--version) - return 0 - ;; + --altdir|--admindir) + _filedir -d + return 0 + ;; + --help|--version) + return 0 + ;; esac # find which mode to use and how many real args used so far @@ -45,43 +45,43 @@ _update_alternatives() done case $mode in - --install) - case $args in - 1) - _filedir + --install) + case $args in + 1) + _filedir + ;; + 2) + _installed_alternatives + ;; + 3) + _filedir + ;; + esac ;; - 2) + --remove) + case $args in + 1) + _installed_alternatives + ;; + 2) + _filedir + ;; + esac + ;; + --auto) _installed_alternatives ;; - 3) - _filedir - ;; - esac - ;; - --remove) - case $args in - 1) + --remove-all) _installed_alternatives ;; - 2) - _filedir + --display) + _installed_alternatives ;; - esac - ;; - --auto) - _installed_alternatives - ;; - --remove-all) - _installed_alternatives - ;; - --display) - _installed_alternatives - ;; - --config) - _installed_alternatives - ;; - *) - COMPREPLY=( $( compgen -W '--verbose --quiet --help --version \ + --config) + _installed_alternatives + ;; + *) + COMPREPLY=( $( compgen -W '--verbose --quiet --help --version \ --altdir --admindir' -- "$cur" ) \ $( compgen -W '--install --remove --auto --display \ --config' -- "$cur" ) ) From 09045a63b642bfaaa11ed843e6fbbc6bcf907c4e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ville=20Skytt=C3=A4?= Date: Wed, 9 Dec 2009 21:23:29 +0200 Subject: [PATCH 08/10] Add update-alternatives --set, --usage, and --slave completions, simplify some bits. --- CHANGES | 3 ++- contrib/update-alternatives | 40 +++++++++++++++++++------------------ 2 files changed, 23 insertions(+), 20 deletions(-) diff --git a/CHANGES b/CHANGES index 1ae6a04d..48de2681 100644 --- a/CHANGES +++ b/CHANGES @@ -24,7 +24,8 @@ bash-completion (2.x) * Apply pine completion to alpine too. * Remove many unnecessary short option completions where long ones exist. * Improve configure, cvs, gkrellm, lftp, mdadm, modprobe, mplayer, - mysqladmin, screen, service, scp, ssh, and general hostname completions. + mysqladmin, screen, service, scp, ssh, update-alternatives, and general + hostname completions. * Add abook and wtf completion, based on work by Raphaël Droz. * Add jarsigner, k3b, lftpget, pack200 and unpack200 completions. * Don't overwrite other host completions when completing from multiple diff --git a/contrib/update-alternatives b/contrib/update-alternatives index 6a3f541d..8694ea26 100644 --- a/contrib/update-alternatives +++ b/contrib/update-alternatives @@ -30,14 +30,14 @@ _update_alternatives() _filedir -d return 0 ;; - --help|--version) + --help|--usage|--version) return 0 ;; esac # find which mode to use and how many real args used so far for (( i=1; i < COMP_CWORD; i++ )); do - if [[ "${COMP_WORDS[i]}" == --@(install|remove|auto|display|config|remove-all) ]]; then + if [[ "${COMP_WORDS[i]}" == --@(install|remove|auto|display|config|remove-all|set) ]]; then mode=${COMP_WORDS[i]} args=$(($COMP_CWORD - i)) break @@ -47,18 +47,30 @@ _update_alternatives() case $mode in --install) case $args in - 1) + 1|3) _filedir ;; 2) _installed_alternatives ;; - 3) - _filedir + 4) + # priority - no completions ;; + *) + case $((args % 4)) in + 0|2) + _filedir + ;; + 1) + COMPREPLY=( $( compgen -W '--slave' -- "$cur" ) ) + ;; + 3) + _installed_alternatives + ;; + esac esac ;; - --remove) + --remove|--set) case $args in 1) _installed_alternatives @@ -68,23 +80,13 @@ _update_alternatives() ;; esac ;; - --auto) - _installed_alternatives - ;; - --remove-all) - _installed_alternatives - ;; - --display) - _installed_alternatives - ;; - --config) + --auto|--remove-all|--display|--config) _installed_alternatives ;; *) COMPREPLY=( $( compgen -W '--verbose --quiet --help --version \ - --altdir --admindir' -- "$cur" ) \ - $( compgen -W '--install --remove --auto --display \ - --config' -- "$cur" ) ) + --altdir --admindir --install --remove --auto --display \ + --config --set' -- "$cur" ) ) esac } complete -F _update_alternatives update-alternatives alternatives From 04b7883f7dd06ffe1f45e90e430c7d3fa03b99b5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ville=20Skytt=C3=A4?= Date: Wed, 9 Dec 2009 22:46:09 +0200 Subject: [PATCH 09/10] Use here strings instead of echos where appropriate (part of Alioth: #312143). --- contrib/_modules | 4 ++-- contrib/findutils | 4 ++-- contrib/gdb | 4 ++-- contrib/java | 2 +- contrib/povray | 4 ++-- contrib/sysv-rc | 14 ++++++-------- contrib/tar | 2 +- contrib/vncviewer | 4 ++-- 8 files changed, 18 insertions(+), 20 deletions(-) diff --git a/contrib/_modules b/contrib/_modules index 33b367c3..b6f51b0b 100644 --- a/contrib/_modules +++ b/contrib/_modules @@ -23,13 +23,13 @@ have module || [ -f /etc/profile.d/modules.sh ] && { _module_list () { - local modules="$( echo $LOADEDMODULES | sed 's/:/ /g' | sort )" + local modules="$( sed 's/:/ /g' <<<$LOADEDMODULES | sort )" compgen -W "$modules" -- $1 } _module_path () { - local modules="$( echo $MODULEPATH | sed 's/:/ /g' | sort )" + local modules="$( sed 's/:/ /g' <<<$MODULEPATH | sort )" compgen -W "$modules" -- $1 } diff --git a/contrib/findutils b/contrib/findutils index 09d2f447..ea0c1121 100644 --- a/contrib/findutils +++ b/contrib/findutils @@ -92,7 +92,7 @@ _find() # opposition to "tests" and "actions", as in the find(1) manpage). onlyonce=' -daystart -depth -follow -help -maxdepth -mindepth -mount \ -noleaf -version -xdev ' - COMPREPLY=( $( echo "${COMP_WORDS[@]}" | \ + COMPREPLY=( $( \ (while read -d ' ' i; do [[ -z "$i" || "${onlyonce/ ${i%% *} / }" == "$onlyonce" ]] && continue @@ -103,7 +103,7 @@ _find() # remove word from list of completions COMPREPLY=( ${COMPREPLY/ ${i%% *} / } ) done - echo "${COMPREPLY[@]}") + echo "${COMPREPLY[@]}") <<<"${COMP_WORDS[@]}" ) ) _filedir diff --git a/contrib/gdb b/contrib/gdb index 0cbf1ec7..04e725cb 100644 --- a/contrib/gdb +++ b/contrib/gdb @@ -20,8 +20,8 @@ _gdb() # functions and aliases. Thus we need to retrieve the program # names manually. IFS=":" - local path_array=( $( echo "$PATH" | \ - sed -e 's/:\{2,\}/:/g' -e 's/^:\|:$//g' ) ) + local path_array=( $( \ + sed -e 's/:\{2,\}/:/g' -e 's/^:\|:$//g' <<<"$PATH" ) ) IFS=$'\n' COMPREPLY=( $( compgen -d -W '$(find "${path_array[@]}" . \ -mindepth 1 -maxdepth 1 -not -type d -executable \ diff --git a/contrib/java b/contrib/java index 068a918f..58562f5d 100644 --- a/contrib/java +++ b/contrib/java @@ -108,7 +108,7 @@ _java_packages() fi done # keep only packages - COMPREPLY=( $( echo "${COMPREPLY[@]}" | tr " " "\n" | grep "/$" ) ) + COMPREPLY=( $( tr " " "\n" <<<"${COMPREPLY[@]}" | grep "/$" ) ) # remove packages extension COMPREPLY=( ${COMPREPLY[@]%/} ) # convert path syntax to package syntax diff --git a/contrib/povray b/contrib/povray index a2ff7b31..c56a71f4 100644 --- a/contrib/povray +++ b/contrib/povray @@ -22,14 +22,14 @@ _povray() ;; [-+]O*) # guess what output file type user may want - case $( ( IFS=$'\n'; echo "${COMP_WORDS[*]}" | grep '^[-+]F' ) ) in + case $( ( IFS=$'\n'; grep '^[-+]F' <<<"${COMP_WORDS[*]}" ) ) in [-+]FN) oext=png ;; [-+]FP) oext=ppm ;; [-+]F[CT]) oext=tga ;; *) oext=$defoext ;; esac # complete filename corresponding to previously specified +I - COMPREPLY=( $( ( IFS=$'\n'; echo "${COMP_WORDS[*]}" | grep '^[-+]I' ) ) ) + COMPREPLY=( $( ( IFS=$'\n'; grep '^[-+]I' <<<"${COMP_WORDS[*]}" ) ) ) COMPREPLY=( ${COMPREPLY[@]#[-+]I} ) COMPREPLY=( ${COMPREPLY[@]/%.pov/.$oext} ) cur="${povcur#[-+]O}" # to confuse _filedir diff --git a/contrib/sysv-rc b/contrib/sysv-rc index a11c9b12..32634dde 100644 --- a/contrib/sysv-rc +++ b/contrib/sysv-rc @@ -19,14 +19,13 @@ _update_rc_d() if [[ $COMP_CWORD -eq 1 || "$prev" == -* ]]; then valid_options=( $( \ - echo "${COMP_WORDS[@]} ${options[@]}" \ - | tr " " "\n" \ - | sed -ne "/$( echo "${options[@]}" | sed "s/ /\\|/g" )/p" \ + tr " " "\n" <<<"${COMP_WORDS[@]} ${options[@]}" \ + | sed -ne "/$( sed "s/ /\\|/g" <<<"${options[@]}" )/p" \ | sort | uniq -u \ ) ) COMPREPLY=( $( compgen -W '${options[@]} ${services[@]}' \ - -X '$( echo ${COMP_WORDS[@]} | tr " " "|" )' -- "$cur" ) ) - elif [[ "$prev" == ?($( echo ${services[@]} | tr " " "|" )) ]]; then + -X '$( tr " " "|" <<<${COMP_WORDS[@]} )' -- "$cur" ) ) + elif [[ "$prev" == ?($( tr " " "|" <<<${services[@]} )) ]]; then COMPREPLY=( $( compgen -W 'remove defaults start stop' -- "$cur" ) ) elif [[ "$prev" == defaults && "$cur" == [0-9] ]]; then COMPREPLY=( 0 1 2 3 4 5 6 7 8 9 ) @@ -86,9 +85,8 @@ _invoke_rc_d() if [[ ($COMP_CWORD -eq 1) || ("$prev" == --* ) ]]; then valid_options=( $( \ - echo ${COMP_WORDS[@]} ${options[@]} \ - | tr " " "\n" \ - | sed -ne "/$( echo ${options[@]} | sed "s/ /\\\\|/g" )/p" \ + tr " " "\n" <<<"${COMP_WORDS[@]} ${options[@]}" \ + | sed -ne "/$( sed "s/ /\\\\|/g" <<<"${options[@]}" )/p" \ | sort | uniq -u \ ) ) COMPREPLY=( $( compgen -W '${valid_options[@]} ${services[@]}' -- "$cur" ) ) diff --git a/contrib/tar b/contrib/tar index 7ca80f71..cf0009c8 100644 --- a/contrib/tar +++ b/contrib/tar @@ -45,7 +45,7 @@ _tar() # complete on files in tar file # # get name of tar file from command line - tar=$( echo "$COMP_LINE" | sed -e 's/^.* \([^ ]*'$regex'\) .*$/\1/' ) + tar=$( sed -e 's/^.* \([^ ]*'$regex'\) .*$/\1/' <<<"$COMP_LINE" ) # devise how to untar and list it untar=t${COMP_WORDS[1]//[^Izjyf]/} diff --git a/contrib/vncviewer b/contrib/vncviewer index 7e9c00da..dd2525ac 100644 --- a/contrib/vncviewer +++ b/contrib/vncviewer @@ -114,8 +114,8 @@ _xvnc4viewer() # Variable 'nocasematch' isn't available; # Convert completions to lowercase COMPREPLY=( $( compgen -W "$( - echo ${options[@]/#/$dash} | tr [:upper:] [:lower:] - )" -- "$(echo "$cur" | tr [:upper:] [:lower:])" ) ) + tr [:upper:] [:lower:] <<<${options[@]/#/$dash} + )" -- "$( tr [:upper:] [:lower:] <<<"$cur" )" ) ) fi else _known_hosts_real "$cur" From 98d439ea462c6629b5cd403b0032217140b9c7c0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ville=20Skytt=C3=A4?= Date: Wed, 9 Dec 2009 22:52:00 +0200 Subject: [PATCH 10/10] Use grep -E instead of deprecated egrep. --- contrib/_modules | 4 ++-- contrib/portupgrade | 4 ++-- contrib/rdesktop | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/contrib/_modules b/contrib/_modules index b6f51b0b..eb6da511 100644 --- a/contrib/_modules +++ b/contrib/_modules @@ -37,7 +37,7 @@ _module_avail () { local modules="$( \ module avail 2>&1 | \ - egrep -v '^(-|$)' | \ + grep -E -v '^(-|$)' | \ xargs printf '%s\n' | sed -e 's/(default)//g' | sort )" compgen -W "$modules" -- $1 @@ -55,7 +55,7 @@ _module () if [ $COMP_CWORD -eq 1 ] ; then # First parameter on line -- we expect it to be a mode selection - options="$( module help 2>&1 | egrep '^[[:space:]]*\+' | \ + options="$( module help 2>&1 | grep -E '^[[:space:]]*\+' | \ awk '{print $2}' | sed -e 's/|/ /g' | sort )" COMPREPLY=( $(compgen -W "$options" -- "$cur") ) diff --git a/contrib/portupgrade b/contrib/portupgrade index 65fa21ba..91278ebd 100644 --- a/contrib/portupgrade +++ b/contrib/portupgrade @@ -36,8 +36,8 @@ _portinstall() [[ "$prev" == -l || "$prev" == -L || "$prev" == -o ]] && return 0 - COMPREPLY=( $( egrep "^$cur" < $indexfile | cut -d'|' -f1 ) ) - COMPREPLY2=( $( egrep "^[^\|]+\|$portsdir$cur" < $indexfile | \ + COMPREPLY=( $( grep -E "^$cur" < $indexfile | cut -d'|' -f1 ) ) + COMPREPLY2=( $( grep -E "^[^\|]+\|$portsdir$cur" < $indexfile | \ cut -d'|' -f2 ) ) COMPREPLY2=( ${COMPREPLY2[@]#$portsdir} ) COMPREPLY=( "${COMPREPLY[@]}" "${COMPREPLY2[@]}" ) diff --git a/contrib/rdesktop b/contrib/rdesktop index 0081adaa..d79ba4ef 100644 --- a/contrib/rdesktop +++ b/contrib/rdesktop @@ -13,7 +13,7 @@ _rdesktop() -k) COMPREPLY=( $( command ls \ /usr/share/rdesktop/keymaps 2>/dev/null | \ - egrep -v '(common|modifiers)' ) ) + grep -E -v '(common|modifiers)' ) ) COMPREPLY=( ${COMPREPLY[@]:-} $( command ls \ $HOME/.rdesktop/keymaps 2>/dev/null ) ) COMPREPLY=( ${COMPREPLY[@]:-} $( command ls \