sshfs-mapper: Fix completion ( map names were not correctly completed )
git-svn-id: https://websvn.glenux.net/svn/Upoc/sshfs-mapper/trunk@1432 eaee96b3-f302-0410-b096-c6cfd47f7835
This commit is contained in:
parent
e04b9075d0
commit
40a681d87b
1 changed files with 3 additions and 2 deletions
|
@ -2,7 +2,7 @@
|
||||||
|
|
||||||
_sshfsmapper_opts()
|
_sshfsmapper_opts()
|
||||||
{
|
{
|
||||||
local cur prev sshfsmapper_opts
|
local cur prev sshfsmapper_opts sshfsmapper_maps
|
||||||
|
|
||||||
COMPREPLY=()
|
COMPREPLY=()
|
||||||
cur="${COMP_WORDS[COMP_CWORD]}"
|
cur="${COMP_WORDS[COMP_CWORD]}"
|
||||||
|
@ -13,7 +13,8 @@ _sshfsmapper_opts()
|
||||||
COMPREPLY=( $( compgen -W "$sshfsmapper_opts" -- $cur ) )
|
COMPREPLY=( $( compgen -W "$sshfsmapper_opts" -- $cur ) )
|
||||||
else
|
else
|
||||||
if [[ "$prev" == -s ]]; then
|
if [[ "$prev" == -s ]]; then
|
||||||
COMPREPLY=( $( sshfs-mapper -l 2> /dev/null ) )
|
sshfsmapper_maps=$( sshfs-mapper -l 2> /dev/null )
|
||||||
|
COMPREPLY=( $( compgen -W "$sshfsmapper_maps" -- $cur ) )
|
||||||
else
|
else
|
||||||
COMPREPLY=( $( compgen -W "$sshfsmapper_opts" -- $cur ) )
|
COMPREPLY=( $( compgen -W "$sshfsmapper_opts" -- $cur ) )
|
||||||
fi
|
fi
|
||||||
|
|
Loading…
Reference in a new issue