From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Jari Aalto Newsgroups: gmane.emacs.bugs Subject: bug#4423: [PATCH] lisp/vc-dispatcher.el: at the end of vc-log-operation run vc-start-logentry-hook Date: Sun, 13 Sep 2009 17:01:28 +0300 Message-ID: <87vdjnlz9j.fsf@jondo.cante.net> Reply-To: Jari Aalto , 4423@emacsbugs.donarmstrong.com NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" X-Trace: ger.gmane.org 1252852045 3457 80.91.229.12 (13 Sep 2009 14:27:25 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sun, 13 Sep 2009 14:27:25 +0000 (UTC) To: Emacs bug BTS Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Sun Sep 13 16:27:18 2009 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1Mmq2v-0005dz-0e for geb-bug-gnu-emacs@m.gmane.org; Sun, 13 Sep 2009 16:27:17 +0200 Original-Received: from localhost ([127.0.0.1]:44549 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Mmq2t-0003Y0-Sa for geb-bug-gnu-emacs@m.gmane.org; Sun, 13 Sep 2009 10:27:15 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1Mmq2n-0003X6-H0 for bug-gnu-emacs@gnu.org; Sun, 13 Sep 2009 10:27:09 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1Mmq2j-0003Vv-Lb for bug-gnu-emacs@gnu.org; Sun, 13 Sep 2009 10:27:09 -0400 Original-Received: from [199.232.76.173] (port=37671 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Mmq2j-0003Vl-Gb for bug-gnu-emacs@gnu.org; Sun, 13 Sep 2009 10:27:05 -0400 Original-Received: from rzlab.ucr.edu ([138.23.92.77]:60914) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1Mmq2i-00058n-82 for bug-gnu-emacs@gnu.org; Sun, 13 Sep 2009 10:27:04 -0400 Original-Received: from rzlab.ucr.edu (rzlab.ucr.edu [127.0.0.1]) by rzlab.ucr.edu (8.14.3/8.14.3/Debian-5) with ESMTP id n8DER0Z5030327; Sun, 13 Sep 2009 07:27:01 -0700 Original-Received: (from debbugs@localhost) by rzlab.ucr.edu (8.14.3/8.14.3/Submit) id n8DEA5tI027175; Sun, 13 Sep 2009 07:10:05 -0700 Resent-Date: Sun, 13 Sep 2009 07:10:05 -0700 X-Loop: owner@emacsbugs.donarmstrong.com Resent-From: Jari Aalto Resent-To: bug-submit-list@donarmstrong.com Resent-CC: Emacs Bugs 2Resent-Date: Sun, 13 Sep 2009 14:10:05 +0000 Resent-Message-ID: Resent-Sender: owner@emacsbugs.donarmstrong.com X-Emacs-PR-Message: report 4423 X-Emacs-PR-Package: emacs X-Emacs-PR-Keywords: Original-Received: via spool by submit@emacsbugs.donarmstrong.com id=B.125285049925085 (code B ref -1); Sun, 13 Sep 2009 14:10:05 +0000 Original-Received: (at submit) by emacsbugs.donarmstrong.com; 13 Sep 2009 14:01:39 +0000 X-Spam-Bayes: score:0.5 Bayes not run. spammytokens:Tokens not available. hammytokens:Tokens not available. Original-Received: from emh05.mail.saunalahti.fi (emh05.mail.saunalahti.fi [62.142.5.111]) by rzlab.ucr.edu (8.14.3/8.14.3/Debian-5) with ESMTP id n8DE1blX025082 for ; Sun, 13 Sep 2009 07:01:38 -0700 Original-Received: from saunalahti-vams (vs3-12.mail.saunalahti.fi [62.142.5.96]) by emh05-2.mail.saunalahti.fi (Postfix) with SMTP id 4830C8BCD8 for ; Sun, 13 Sep 2009 17:01:34 +0300 (EEST) Original-Received: from emh01.mail.saunalahti.fi ([62.142.5.107]) by vs3-12.mail.saunalahti.fi ([62.142.5.96]) with SMTP (gateway) id A049D33ACDE; Sun, 13 Sep 2009 17:01:34 +0300 Original-Received: from picasso.cante.net (a91-155-187-216.elisa-laajakaista.fi [91.155.187.216]) by emh01.mail.saunalahti.fi (Postfix) with ESMTP id 35F04403E for ; Sun, 13 Sep 2009 17:01:28 +0300 (EEST) Original-Received: from [192.168.1.7] (helo=jondo.cante.net) by picasso.cante.net with esmtp (Exim 4.69) (envelope-from ) id 1Mmpdv-00051L-7Q for submit@emacsbugs.donarmstrong.com; Sun, 13 Sep 2009 17:01:27 +0300 Original-Received: from jaalto by jondo.cante.net with local (Exim 4.69) (envelope-from ) id 1Mmpdw-0004F0-9O for submit@emacsbugs.donarmstrong.com; Sun, 13 Sep 2009 17:01:28 +0300 X-SA-Exim-Connect-IP: 192.168.1.7 X-SA-Exim-Mail-From: jari.aalto@cante.net X-SA-Exim-Scanned: No (on picasso.cante.net); SAEximRunCond expanded to false X-Antivirus: VAMS X-detected-operating-system: by monty-python.gnu.org: GNU/Linux 2.6 (newer, 2) Resent-Date: Sun, 13 Sep 2009 10:27:09 -0400 X-BeenThere: bug-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:31036 Archived-At: --=-=-= This new hook allows users to set up the initial contents of *VC-Log* buffer. 2009-09-13 Jari Aalto * vc-dispatcher.el (vc-start-logentry-hook): New user variable. (vc-start-logentry): run `vc-start-logentry-hook' at end. --=-=-= Content-Type: text/x-diff Content-Disposition: inline; filename=0001-lisp-vc-dispatcher.el-at-end-of-vc-log-operation-run.patch >From 623988d6819a83f897c218db8a637fc505afd1b6 Mon Sep 17 00:00:00 2001 From: Jari Aalto Date: Sun, 13 Sep 2009 16:56:51 +0300 Subject: [PATCH] lisp/vc-dispatcher.el: at end of vc-log-operation run vc-start-logentry-hook Signed-off-by: Jari Aalto --- lisp/vc-dispatcher.el | 14 ++++++++++++-- 1 files changed, 12 insertions(+), 2 deletions(-) diff --git a/lisp/vc-dispatcher.el b/lisp/vc-dispatcher.el index a209e13..4282e52 100644 --- a/lisp/vc-dispatcher.el +++ b/lisp/vc-dispatcher.el @@ -136,6 +136,13 @@ preserve the setting." :type 'boolean :group 'vc) +(defcustom vc-start-logentry-hook nil + "Normal hook (list of functions) run after `vc-start-logentry'. +See `run-hooks'." + :type 'hook + :group 'vc + :version "23.2") + ;; Variables the user doesn't need to know about. (defvar vc-log-operation nil) @@ -541,7 +548,9 @@ INITIAL-CONTENTS is nil, do action immediately as if the user had entered COMMENT. If COMMENT is t, also do action immediately with an empty comment. Remember the file's buffer in `vc-parent-buffer' \(current one if no file). AFTER-HOOK specifies the local value -for `vc-log-after-operation-hook'." +for `vc-log-after-operation-hook'. + +At the end, runs the normal hook `vc-start-logentry-hook'." (let ((parent (if (vc-dispatcher-browsing) ;; If we are called from a directory browser, the parent buffer is @@ -567,7 +576,8 @@ for `vc-log-after-operation-hook'." (when (stringp comment) (insert comment))) (if (or (not comment) initial-contents) (message "%s Type C-c C-c when done" msg) - (vc-finish-logentry (eq comment t))))) + (vc-finish-logentry (eq comment t))) + (run-hooks 'vc-start-logentry-hook))) (declare-function vc-dir-move-to-goal-column "vc-dir" ()) -- 1.6.3.3 --=-=-=--