zsh-workers
 help / color / mirror / code / Atom feed
From: Lyn Fugmann <me@fugi.dev>
To: Bart Schaefer <schaefer@brasslantern.com>
Cc: zsh-workers@zsh.org, Mikael Magnusson <mikachu@gmail.com>
Subject: Re: [PATCH] remote files completion: remove double-escaping
Date: Tue, 28 May 2024 17:40:11 +0200	[thread overview]
Message-ID: <c2023eff-987e-4dc9-bac2-975aee10be22@fugi.dev> (raw)
In-Reply-To: <CAH+w=7YE-g0gLu9S6JF_SpM53PahgMC7SJu3_OX5k=qv041Vug@mail.gmail.com>

On 2024-04-12 20:59, Bart Schaefer wrote:
> On Wed, Apr 10, 2024 at 11:45 AM Mikael Magnusson <mikachu@gmail.com> wrote:
>>
>> On Wed, Apr 10, 2024 at 12:47 PM Lyn Fugmann <me@fugi.dev> wrote:
>>>
>>> Removes the double escaping in the remote files completion. This affects rsync and scp.
>>> For example, instead of a space character in a remote filename turning into `\\\ `, it will now correctly turn into `\ `.
>>> While scp apparently works with either one, rsync requires the latter since version 3.2.4[1] (unless the legacy behavior is explicitly enabled).
>>> This has been a problem for almost two years now.
>>
>> This should probably be behind a zstyle (I guess it's fine if it
>> defaults to the new behavior), as currently this patch will break
>> completion for older versions of scp and rsync. That way users can
>> easily configure it per command or globally if they want.
> 
> Doesn't this actually depend on the remote version rather than the
> local command?  Might need to be configurable based on the
> destination?
> 
> See also thread starting with workers/50484 from 2022 Subject: rsync completions

I finally got around to testing this. The behavior appears to depend 
only on the local version of rsync, not on the remote version. Tested 
using local rsync 3.2.3 and 3.2.7, remote rsync 3.1.3 and 3.2.7. So I 
think the patch should be fine as is. (I would expect very few people to 
run an over two years old version of rsync and a recent version of zsh 
on the same local machine.)


      reply	other threads:[~2024-05-28 15:41 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-04-10 10:46 Lyn Fugmann
2024-04-10 18:45 ` Mikael Magnusson
2024-04-12 18:59   ` Bart Schaefer
2024-05-28 15:40     ` Lyn Fugmann [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=c2023eff-987e-4dc9-bac2-975aee10be22@fugi.dev \
    --to=me@fugi.dev \
    --cc=mikachu@gmail.com \
    --cc=schaefer@brasslantern.com \
    --cc=zsh-workers@zsh.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/zsh/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).