unofficial mirror of help-gnu-emacs@gnu.org
 help / color / mirror / Atom feed
From: David Kastrup <dak@gnu.org>
To: help-gnu-emacs@gnu.org
Subject: Re: Show unsaved changes (as diff)
Date: Sun, 23 Sep 2007 16:39:59 +0200	[thread overview]
Message-ID: <85tzplo37k.fsf@lola.goethe.zz> (raw)
In-Reply-To: wnzk5qh78ve.fsf@g22.physik.fu-berlin.de

Florian Lorenzen <lorenzen@physik.fu-berlin.de> writes:

> Hello,
>
> I have a very innocent question, I'm sorry that I could not figure out
> the answer myself: is there a quick way to ask Emacs to show the
> unsaved changes in a file's buffer as a diff? Sometimes, I attempt to
> kill a bufer and Emacs asks me if I want do discard the changes. As my
> memory is very weak sometimes, I cannot recall what I had changed and
> if this was important in any way. So, I'd simply like to see what I'd
> throw away. Of course, I can copy the file's buffer's content to a new
> buffer, revert the file's buffer and make a diff on these two. But is
> there something ready-made for this kind of situation, like M-x
> show-unsaved-changes?

M-x diff-buffer-with-file RET

-- 
David Kastrup, Kriemhildstr. 15, 44793 Bochum

  reply	other threads:[~2007-09-23 14:39 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-09-23 14:29 Show unsaved changes (as diff) Florian Lorenzen
2007-09-23 14:39 ` David Kastrup [this message]
2007-09-24 17:44   ` Martin Fischer
2007-09-25  5:54     ` Gordon Beaton
2007-09-25  7:14     ` Thierry Volpiatto

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

  List information: https://www.gnu.org/software/emacs/

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

  git send-email \
    --in-reply-to=85tzplo37k.fsf@lola.goethe.zz \
    --to=dak@gnu.org \
    --cc=help-gnu-emacs@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.
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).