diff --git a/CHANGES b/CHANGES index 88339dae..630af854 100644 --- a/CHANGES +++ b/CHANGES @@ -86,6 +86,9 @@ bash-completion (2.x) [ Ildar Mulyukov ] * Add showmount completion (Alioth: #312285). + [ Neville Gao ] + * Fix mount completion error "bash: [: too many arguments" (Alioth #312381). + -- David Paleino Sun, 11 Oct 2009 11:11:57 +0200 bash-completion (1.1) diff --git a/contrib/mount b/contrib/mount index 0c7fad83..daf472ce 100644 --- a/contrib/mount +++ b/contrib/mount @@ -111,9 +111,9 @@ _mount() COMPREPLY=( $( compgen -W "$( mount | awk '! /^[ \t]*#/ {if ($3 ~ /\//) print $3}' )" -- "$cur" ) ) else # probably Linux - if [ $prev = -L ]; then + if [ "$prev" = -L ]; then _linux_fstab -L < /etc/fstab - elif [ $prev = -U ]; then + elif [ "$prev" = -U ]; then COMPREPLY=( $( compgen -W '$(sed -ne "s/^[[:space:]]*UUID=\([^[:space:]]*\).*/\1/p" /etc/fstab )' -- "$cur" ) ) else _linux_fstab < /etc/fstab