Fix nfs mount completion if the path to showmount contains a space.
This commit is contained in:
parent
c3bb4416d7
commit
aac11de466
@ -17,7 +17,7 @@ _mount()
|
|||||||
[[ "$cur" == \\ ]] && cur="/"
|
[[ "$cur" == \\ ]] && cur="/"
|
||||||
|
|
||||||
if [[ "$cur" == *:* ]]; then
|
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
|
[ -x "$sm" ] || continue
|
||||||
COMPREPLY=( $( compgen -W "$( "$sm" -e ${cur%%:*} | \
|
COMPREPLY=( $( compgen -W "$( "$sm" -e ${cur%%:*} | \
|
||||||
awk 'NR>1 {print $1}' )" -- "${cur#*:}" ) )
|
awk 'NR>1 {print $1}' )" -- "${cur#*:}" ) )
|
||||||
|
Loading…
x
Reference in New Issue
Block a user