summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCrestez Dan Leonard <cdleonard@gmail.com>2010-02-02 11:17:33 +0200
committerCrestez Dan Leonard <cdleonard@gmail.com>2010-02-02 11:17:33 +0200
commitaac11de466f9a22312329e91769d0c84ae347407 (patch)
tree084668f936a6468ab1c7f1a40b5de0d96fe5bb0c
parentc3bb4416d71dfb73c813179e2b4a37767e5adb0d (diff)
downloadbash-completion-aac11de466f9a22312329e91769d0c84ae347407.tar.gz
Fix nfs mount completion if the path to showmount contains a space.
-rw-r--r--contrib/mount2
1 files changed, 1 insertions, 1 deletions
diff --git a/contrib/mount b/contrib/mount
index d8ba81bc..1f0d8a4a 100644
--- a/contrib/mount
+++ b/contrib/mount
@@ -17,7 +17,7 @@ _mount()
[[ "$cur" == \\ ]] && cur="/"
if [[ "$cur" == *:* ]]; then
- for sm in $(type -P showmount) {,/usr}/{,s}bin/showmount; do
+ for sm in "$(type -P showmount)" {,/usr}/{,s}bin/showmount; do
[ -x "$sm" ] || continue
COMPREPLY=( $( compgen -W "$( "$sm" -e ${cur%%:*} | \
awk 'NR>1 {print $1}' )" -- "${cur#*:}" ) )