unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
* bug#38707: dired-do-rename doesn't check for "/" !
@ 2019-12-22 16:37 積丹尼 Dan Jacobson
  2019-12-24  4:28 ` Nick Helm
  0 siblings, 1 reply; 3+ messages in thread
From: 積丹尼 Dan Jacobson @ 2019-12-22 16:37 UTC (permalink / raw)
  To: 38707

R runs the command dired-do-rename (found in dired-mode-map), which is
an interactive autoloaded compiled Lisp function in ‘dired-aux.el’.

But it has a big bug.

Let's say you tell it to rename qqq to "xxx/yyy/zzz/".

And it works.

You get xxx/yyy/zzz/qqq

But if there is no directory zzz,
then one day you will discover you got

xxx/yyy/qqq .

Real "mv" doesn't have this bug.

$ mv k /tmp/p/
mv: cannot create regular file '/tmp/p/': Not a directory

dired-do-rename perhaps under the hood does the "mv" action, but instead
of reporting the failure, tries again with the final slash removed!

emacs-version "26.3"





^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2020-08-06 10:13 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-12-22 16:37 bug#38707: dired-do-rename doesn't check for "/" ! 積丹尼 Dan Jacobson
2019-12-24  4:28 ` Nick Helm
2020-08-06 10:13   ` Lars Ingebrigtsen

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

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 read-only IMAP folder(s) and NNTP newsgroup(s).