[Bash-completion-devel] [bash-completion-Bugs][312285] nfs mount completion broken
bash-completion-bugs at alioth.debian.org
bash-completion-bugs at alioth.debian.org
Sat Jan 23 04:56:02 UTC 2010
Bugs item #312285, was changed at 23.01.2010 01:03 by Ildar Mulyukov
You can respond by visiting:
https://alioth.debian.org/tracker/?func=detail&atid=413095&aid=312285&group_id=100114
Status: Open
Priority: 3
Submitted By: Leonard Crestez (cdleonard-guest)
Assigned to: Nobody (None)
Summary: nfs mount completion broken
Distribution: None
Originally reported in: None
Milestone: None
Status: None
Original bug number:
Initial Comment:
Original report by "Ildar Mulyukov <ildar at users.sourceforge.net>" to the bash-completion-devel list.
"""
hi! I checked current GIT. This completes wrong:
$ mount nfsserver:/<TAB>
bin/ etc/ lost+found/ opt/ sbin/ tmp/
boot/ home/ media/ proc/ srv/ usr/
dev/ lib/ mnt/ root/ sys/ var/
I couldn't debug it myself, sorry :-(
Best regards,
"""
It's very likely that this is because COMP_WORDBREAKS now contains a colon. I don't use NFS; could somebody else test the following tiny patch?
diff --git a/contrib/mount b/contrib/mount
index 0474df0..99e77b4 100644
--- a/contrib/mount
+++ b/contrib/mount
@@ -12,9 +12,9 @@ _mount()
local cur i sm host prev
COMPREPLY=()
- cur=`_get_cword`
+ cur=`_get_cword ':'`
+ prev=`_get_pword ':'`
[[ "$cur" == \\ ]] && cur="/"
- prev=${COMP_WORDS[COMP_CWORD-1]}
for i in {,/usr}/{,s}bin/showmount; do [ -x $i ] && sm=$i && break; done
----------------------------------------------------------------------
Comment By: Ildar Mulyukov (ildar-guest)
Date: 23.01.2010 10:56
Message:
Hi, Leonard!
Thanks for opening this bug.
Unfortunately your patch doesn't fix the problem.
While you don't use NFS, you can fake it with a simple script. Name it showmount and put in PATHs before /usr/sbin:
#!/bin/sh
echo /1
echo /1/2
echo /3
----------------------------------------------------------------------
You can respond by visiting:
https://alioth.debian.org/tracker/?func=detail&atid=413095&aid=312285&group_id=100114
More information about the Bash-completion-devel
mailing list