[Bash-completion-devel] [bash-completion-Bugs][312176] get_cword merging change broke completion of remote scp paths w/spaces

bash-completion-bugs at alioth.debian.org bash-completion-bugs at alioth.debian.org
Tue Dec 22 18:31:03 UTC 2009


Bugs item #312176, was opened at 2009-12-22 20:31 by Ville Skyttä 
You can respond by visiting: 
https://alioth.debian.org/tracker/?func=detail&atid=413095&aid=312176&group_id=100114

Status: Open
Priority: 3
Submitted By: Ville Skyttä  (scop-guest)
Assigned to: Freddy Vulto (fvu-guest)
Summary: get_cword merging change broke completion of remote scp paths w/spaces 
Distribution: None
Originally reported in: None
Milestone: None
Status: None
Original bug number: 


Initial Comment:
"Merged __get_cword3 & __get_cword4 to _get_cword"
http://git.debian.org/?p=bash-completion/bash-completion.git;a=commitdiff;h=08c587848368a54e4d3e813bf37dad4be6fe10b7

This change broke scp completion of paths containing spaces (possibly other "difficult" characters as well, haven't tested yet).  Given a remote system with dirs "/tmp/foo bar" and "/tmp/foo quux", before the above change, this:

scp remote:/tmp/foo<TAB>

...expanded to:

scp remote:/tmp/foo\\\   # <-- one trailing space after three backslashes

...which after hitting tab again resulted in completion suggestions:

/tmp/foo\\\ bar/   /tmp/foo\\\ quux/

This is the desired behavior.  But after the above mentioned change, the last step:

scp remote:/tmp/foo\\\ <TAB> # <-- one space before <TAB>

...results in completion suggestions which are the files and dirs from my remote home dir.

This is with 4.0.23(1)-release (Fedora 11, bash-4.0-9.fc11.x86_64).

----------------------------------------------------------------------

You can respond by visiting: 
https://alioth.debian.org/tracker/?func=detail&atid=413095&aid=312176&group_id=100114



More information about the Bash-completion-devel mailing list