unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Dan Nicolaescu <dann@gnu.org>
To: 6447@debbugs.gnu.org
Subject: bug#6447: 23.1; revert-buffer in *vc-diff*
Date: Fri, 09 Jul 2010 16:51:54 -0400	[thread overview]
Message-ID: <yxqlj9k5qfp.fsf@fencepost.gnu.org> (raw)
In-Reply-To: <87y6e46r37.fsf@mail.jurta.org> (Juri Linkov's message of "Fri\,  25 Jun 2010 00\:47\:08 +0300")

Juri Linkov <juri@jurta.org> writes:

>>> Like the command `diff' after calling `diff-mode' sets
>>> `revert-buffer-function' to lambda with its function arguments,
>>> `vc-diff-internal' could do the same:
>>>
>>> === modified file 'lisp/vc/vc.el'
>>> --- lisp/vc/vc.el	2010-06-11 19:09:57 +0000
>>> +++ lisp/vc/vc.el	2010-06-19 14:51:14 +0000
>>> @@ -1547,6 +1547,9 @@ (defun vc-diff-internal (async vc-filese
>>>            (message "%s" (cdr messages))
>>>            nil)
>>>        (diff-mode)
>>> +      (set (make-local-variable 'revert-buffer-function)
>>> +	   `(lambda (ignore-auto noconfirm)
>>> +	      (vc-diff-internal ,async ',vc-fileset ,rev1 ,rev2 ,verbose)))
>>>        ;; Make the *vc-diff* buffer read only, the diff-mode key
>>>        ;; bindings are nicer for read only buffers. pcl-cvs does the
>>>        ;; same thing.
>>
>> Looks like a fine idea, please go ahead.
>
> Done.

It would be nice to also have revert-buffer bound to "g" in this case,
that would make this feature easier to use (and consistent with what
we do for other modes).





  parent reply	other threads:[~2010-07-09 20:51 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-06-17 17:14 bug#6447: 23.1; revert-buffer in *vc-diff* Tom Tromey
2010-06-19 14:52 ` Juri Linkov
2010-06-19 17:36   ` Chong Yidong
2010-06-24 21:47     ` Juri Linkov
2010-06-24 23:16       ` Dan Nicolaescu
2010-06-25 20:32         ` Juri Linkov
2010-06-25 21:12           ` Dan Nicolaescu
2010-08-06  4:04         ` Dan Nicolaescu
2010-07-09 20:51       ` Dan Nicolaescu [this message]
2010-08-02  9:26         ` Stefan Monnier
2010-08-06  4:03           ` Dan Nicolaescu

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=yxqlj9k5qfp.fsf@fencepost.gnu.org \
    --to=dann@gnu.org \
    --cc=6447@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 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).