-
Notifications
You must be signed in to change notification settings - Fork 374
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
rsync ssh remote paths are double-escaped (incorrect since rsync 3.2.4) #848
Comments
Rogach
added a commit
to Rogach/bash-completion
that referenced
this issue
Mar 29, 2023
Fixes scop#848. If a remote machine contains a file named `a b`, completing rsync command results in `rsync remote:a\\\ b`, which results in rsync failing to find the file. This commit removes the extra slashes, and now completion results in `rsync remote:a\ b`. scp somehow accepts both variants, so this change won't break it.
Rogach
added a commit
to Rogach/bash-completion
that referenced
this issue
Jun 18, 2023
Fixes scop#848. If a remote machine contains a file named `a b`, completing rsync command results in `rsync remote:a\\\ b`, which results in rsync failing to find the file. This commit removes the extra slashes, and now completion results in `rsync remote:a\ b`. scp somehow accepts both variants, so this change won't break it.
One year later the problem still there. |
Just got bitten by this. I'd be very grateful for this fix to be merged. Thank you :) |
akinomyoga
pushed a commit
to Rogach/bash-completion
that referenced
this issue
Oct 8, 2023
Fixes scop#848. If a remote machine contains a file named `a b`, completing rsync command results in `rsync remote:a\\\ b`, which results in rsync failing to find the file. This commit removes the extra slashes, and now completion results in `rsync remote:a\ b`. scp somehow accepts both variants, so this change won't break it.
akinomyoga
pushed a commit
to Rogach/bash-completion
that referenced
this issue
May 13, 2024
Fixes scop#848. If a remote machine contains a file named `a b`, completing rsync command results in `rsync remote:a\\\ b`, which results in rsync failing to find the file. This commit removes the extra slashes, and now completion results in `rsync remote:a\ b`. scp somehow accepts both variants, so this change won't break it.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Describe the bug
In 3.2.4 rsync changed the default way that arguments were passed to a remote ssh host, to no longer require double-escaping.
The bash-completion still double-escapes.
To reproduce
/tmp/foo bar
on a remote machine (namedremote
)rsync remote:/tmp/foo
rsync remote:/tmp/foo\\\ bar
, which is incorrect.Expected behaviour
The remote path should only be escaped once, not twice (unless the
--old-args
argument is passed to rsync (>= 3.2.4)Versions (please complete the following information)
echo "$BASH_VERSION"
:5.2.2(1)-release
(IFS=.; echo "${BASH_COMPLETION_VERSINFO[*]}")
:2.11
(Debian:1:2.11-6
)The text was updated successfully, but these errors were encountered: