Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 297818

Summary: app-shells/bash-completion-1.1-r4: rsync script does not correctly complete host: word with ssh connection.
Product: Gentoo Linux Reporter: pouexmachinax
Component: [OLD] UnspecifiedAssignee: Gentoo Shell Tools project <shell-tools>
Status: RESOLVED FIXED    
Severity: normal    
Priority: High    
Version: unspecified   
Hardware: All   
OS: Linux   
Whiteboard:
Package list:
Runtime testing required: ---
Attachments: New ebuild fixing rsync ssh remote path completion

Description pouexmachinax 2009-12-21 18:34:56 UTC
When you try to complete a path of the host:... form the rsync script does not do it correctly. If you look at the code, it is the same as the scp code in the ssh script. The only difference is that the scp code has

cur=`_get_cword ":"`

but the rsync script has

cur = `_get_cword`

If you change for the scp version it works correctly.

The only problem is I'm not sure if it might break something else for rsync bash completion...

Reproducible: Always

Steps to Reproduce:
1. Type rsync hostname:
2. Press <tab>
 
Actual Results:  
You will see a list of local files and directories.

Expected Results:  
List of remote files and directories.
Comment 1 pouexmachinax 2009-12-21 18:42:58 UTC
Created attachment 213701 [details]
New ebuild fixing rsync ssh remote path completion

It fixes it with a sed one liner.
Comment 2 pouexmachinax 2009-12-21 18:43:59 UTC
By the way, bug is not fixed in upstream. I will report bug there too but pending new version, I think it should be fixed here.
Comment 3 Jeremy Olexa (darkside) (RETIRED) archtester gentoo-dev Security 2009-12-21 18:47:30 UTC
Nice find, please include your upstream reference here.
Comment 5 pouexmachinax 2009-12-23 18:20:57 UTC
Bug has been fixed in upstream repository. Can we still add a fix to the stable gentoo version?
Comment 6 Jeremy Olexa (darkside) (RETIRED) archtester gentoo-dev Security 2009-12-25 02:33:41 UTC
thanks, added to -r5