all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Stefan Monnier <monnier@iro.umontreal.ca>
To: Dmitry Gutov <dgutov@yandex.ru>
Cc: emacs-devel@gnu.org
Subject: Re: trunk r115265: * lisp/vc/vc-dispatcher.el (vc-log-edit): Setup the Summary&Author headers.
Date: Sun, 01 Dec 2013 16:10:34 -0500	[thread overview]
Message-ID: <jwvzjok477k.fsf-monnier+emacs@gnu.org> (raw)
In-Reply-To: <529A0C08.8010809@yandex.ru> (Dmitry Gutov's message of "Sat, 30 Nov 2013 18:02:16 +0200")

>> Seems a bit pointless since C-x k (and kill-this-buffer) works as well
>> for *VC-Log*, AFAIK.
> Why do we have `message-kill-buffer', `rcirc-multiline-minor-cancel' and
> org-kill-note-or-show-branches'?

Can't tell you without looking at them.  Presumably they do more than
just kill the buffer and using a kill-buffer-hook was not an option..
In the case of message-kill-buffer' it seems to be trying to deal with
the fact that the content of the buffer is like that of an unsaved file,
but buffer-file-name is non-nil, so it can't rely on the standard
kill-buffer handling.

In the case of *VC-Log* we could have a kill-buffer-hook which prompts
the user and aborts the kill if the user says he doesn't want to throw
away his incomplete comment.  But as you point out below, we could also
instead have a kill-buffer-hook which saves the incomplete comment to
log-edit-comment-ring so the buffer can be deleted without losing
valuable info and hence without prompting.

> As I see it, they mean "abort the current action, clean up its data, restore
> the previous window configuration". Having a similar command with the same
> binding in log-edit would be natural. Among other things, it would delete
> the *log-edit-files* window and quit-window on the current buffer (maybe
> deleting the window as a result).

We might indeed provide a key to "hide" the *VC-Log* buffer without
killing it.  And that should hide (or kill) the *log-edit-files* as well.

> We can go against the similar commands and refrain from killing the buffer,
> but why keep it? We can also save the aborted commit message to
> log-edit-comment-ring.

As long as the data is stored in log-edit-comment-ring I think it's OK
to kill without prompting.


        Stefan



  reply	other threads:[~2013-12-01 21:10 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <E1VlqjS-0006O3-Fn@vcs.savannah.gnu.org>
2013-11-29  4:39 ` trunk r115265: * lisp/vc/vc-dispatcher.el (vc-log-edit): Setup the Summary&Author headers Dmitry Gutov
2013-11-29 13:33   ` Stefan Monnier
2013-11-29 14:53     ` Dmitry Gutov
2013-11-29 17:04       ` Stefan Monnier
2013-11-29 22:37         ` Dmitry Gutov
2013-11-30  2:29           ` Stefan Monnier
2013-11-30 16:02             ` Dmitry Gutov
2013-12-01 21:10               ` Stefan Monnier [this message]
2013-12-02  2:40                 ` Dmitry Gutov
2013-12-02 13:53                   ` Stefan Monnier
2013-12-02 23:02                     ` Dmitry Gutov
2013-12-03  0:56                       ` Leo Liu
2013-12-03  3:06                       ` Stefan Monnier
2013-12-04  0:38                         ` Dmitry Gutov
2013-12-03  2:17                     ` Dmitry Gutov
2013-12-03  3:09                       ` Stefan Monnier
2013-12-04  0:43                         ` Dmitry Gutov

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=jwvzjok477k.fsf-monnier+emacs@gnu.org \
    --to=monnier@iro.umontreal.ca \
    --cc=dgutov@yandex.ru \
    --cc=emacs-devel@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.