all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: "積丹尼 Dan Jacobson" <jidanni@jidanni.org>
To: 24474@debbugs.gnu.org
Subject: bug#24474: dired-diff doesn't know about backup-directory-alist
Date: Mon, 19 Sep 2016 23:40:37 +0800	[thread overview]
Message-ID: <8760przymi.fsf@jidanni.org> (raw)

= 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".]





             reply	other threads:[~2016-09-19 15:40 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-09-19 15:40 積丹尼 Dan Jacobson [this message]
2016-09-20  1:40 ` bug#24474: dired-diff doesn't know about backup-directory-alist npostavs

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=8760przymi.fsf@jidanni.org \
    --to=jidanni@jidanni.org \
    --cc=24474@debbugs.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

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

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.