Subject: bug#64531: [PATCH v2] Add new command vc-dir-copy-filename-as-kill

From: Eli Zaretskii <[email-masked]>
Date: Sun, 20 Aug 2023 09:26:12 +0300

> Date: Sun, 20 Aug 2023 02:33:59 +0300
> Cc: [email-masked]
> From: Dmitry Gutov <[email-masked]>
> 
> The difference from dired-copy-filename-as-kill in handing of the prefix 
> argument looks unfortunate (as a principle), but I'd rather leave it for 
> you to judge. Perhaps changing the latter command's interface would be a 
> better choice; I'm not sure why it works that way.

What difference is that?  I must be missing something, since it sounds
like both commands use the argument to select absolute or relative
file names?

> Implementation difference: instead of going through (format "%S"), this 
> one uses shell-quote-argument. Is that good enough for Windows systems?

It depends on how the result will be used.  But maybe we should do the
same as dired-copy-filename-as-kill, just for consistency of the UX?

> And one more difference which we might want to see fixed:
> 
>    (When there's a single file, no quoting is done.)
> 
> It seems like, at least, in some usage scenarios users would prefer to 
> have copied filename not quoted. E.g. for subsequent use with find-file 
> or... something similar. I don't really use this command all that much, 
> so maybe I'm mistaken here, though.

There will always be cases when quoting gets in the way, but hopefully
they are rare.  The important thing, IMO, is that quoting is useful
for many/most uses of the file names in VC commands.  Is it?