emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: PR: dired-do-create-files now checks for trailing slashes in the tar


From: Tassilo Horn
Subject: Re: PR: dired-do-create-files now checks for trailing slashes in the target
Date: Wed, 29 Sep 2021 15:37:08 +0200
User-agent: mu4e 1.7.0; emacs 28.0.50

Rudi C <rudiwillalwaysloveyou@gmail.com> writes:

>> how do I rename old_name into new_name so that it overwrites new_name
>
> Overwriting a directory is a highly destructive activity. It would be
> better to make the user explicitly delete the old directory, and then
> do the rename IMO.

I would agree.  And while it could made work for the target being an
empty directory, hopefully nobody will assume this to be a sensible
operation if the target is a non-empty directory.

> But we can add a new custom variable. I am all for giving everyone
> options.  I don't think it can integrate with
> `dired-create-destination-dirs' though;
> `dired-create-destination-dirs-trailing-slash-special'?

Have a look at my reply to Eli.  AFAICS, dired doesn't overwrite a
directory even without your patch when you rename a directory foo to bar
which already exists.  It also moves foo into bar.

So from my POV, no new defcustom is needed.

Bye,
Tassilo



reply via email to

[Prev in Thread] Current Thread [Next in Thread]