Subject: bug#10458: 24.0.92; ! in dired on a file starting with a hyphen

From: Lars Ingebrigtsen <[email-masked]>
Date: Sun, 20 Feb 2022 14:50:36 +0100

Stefan Monnier <[email-masked]> writes:

> Indeed.  Quoting the file name by doing something like:
>
>     foobar '-toto' titi
>
> won't help (`foobar' won't see the quoting anyway because the shell
> will strip it away before passing the result to `foobar').
> But we could do something like:
>
>    foobar ./-toto titi
>
> which would not suffer from this problem.

(I'm going through old bug reports that unfortunately weren't resolved
at the time.)

The discussion then turned to whether "--" was a possibility, and it
isn't.

But adding ./ to file names that start with - should be safe, I think?
So I've now done that in Emacs 29.

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no