Subject: Re: bug#56511: 29.0.50; Wishes: to use delete-by-moving-to-trash, but not with Tramp? or .dir-locals.el with Tramp

From: Lars Ingebrigtsen <[email-masked]>
Date: Tue, 12 Jul 2022 15:05:14 +0200

Jean Louis <[email-masked]> writes:

> How to use the variable `delete-by-moving-to-trash', but not with
> Tramp?

As the doc string of move-file-to-trash says:

If the function `system-move-file-to-trash' is defined, call it
 with FILENAME as an argument.

So just define a function that checks whether FILENAME is a Tramp file
name or not, and delete the file if it is, but trash otherwise.

So I don't think there's anything to be done here on the Emacs side, and
I'm closing this bug report.

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