GNU bug report logs -
#24474
dired-diff doesn't know about backup-directory-alist
Previous Next
Reported by: 積丹尼 Dan Jacobson <jidanni <at> jidanni.org>
Date: Mon, 19 Sep 2016 23:17:02 UTC
Severity: minor
Merged with 30407
Found in version 25.1
Fixed in version 26.1
Done: Glenn Morris <rgm <at> gnu.org>
Bug is archived. No further changes may be made.
Full log
Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):
= runs the command dired-diff, which is an interactive autoloaded
compiled Lisp function in `dired-aux.el'.
It is bound to =, <menu-bar> <immediate> <diff>.
(dired-diff FILE &optional SWITCHES)
Compare file at point with file FILE using `diff'.
If called interactively, prompt for FILE. If the file at point
has a backup file, use that as the default. If the file at point
is a backup file, use its original...
[OK, let's try it. Oops:]
diff -U0 /home/jidanni/\!home\!jidanni\!.bash_profile.\~42\~ /home/jidanni/.bash_profile
diff: /home/jidanni/!home!jidanni!.bash_profile.~42~: No such file or directory
Diff finished (diff error). Mon Sep 19 23:25:22 2016
[Which is because the correct file name is:]
/home/jidanni/.backups/!home!jidanni!.bash_profile.~42~
[because of my:]
backup-directory-alist is a variable defined in `files.el'.
Its value is ((".*" . "~/.backups/"))
Original value was nil
[So we see that dired-diff got the filename right, but the directory
wrong.
Furthermore, "if the file at point is a backup file..." also fails
miserably. Go to your ~/.backups directory and try it on a few files...]
diff -U0 /home/jidanni/.backups/\!home\!jidanni\!.bash_profile.\~42\~ /home/jidanni/.backups/\!home\!jidanni\!.bash_profile
diff: /home/jidanni/.backups/!home!jidanni!.bash_profile: No such file or directory
Diff finished (diff error). Mon Sep 19 23:37:10 2016
[We see it assumes everything is in the same directory.
It should have tried comparing ~/.bash_profile .
emacs-version "24.5.1".]
This bug report was last modified 7 years and 160 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.