changeset 104369:5744c85d533a

* log-edit.el (log-edit-strip-single-file-name): New var. (log-edit-insert-changelog): Use it.
author Stefan Monnier <monnier@iro.umontreal.ca>
date Wed, 19 Aug 2009 19:55:58 +0000
parents f700ef41d26c
children 6d088d4b6e1f
files etc/NEWS lisp/ChangeLog lisp/log-edit.el
diffstat 3 files changed, 14 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/etc/NEWS	Wed Aug 19 19:42:25 2009 +0000
+++ b/etc/NEWS	Wed Aug 19 19:55:58 2009 +0000
@@ -142,6 +142,9 @@
 
 **** vc-dir displays the stash status
 
+*** log-edit-strip-single-file-name controls whether or not single filenames
+are stripped when copying text from the ChangeLog to the *VC-Log* buffer.
+
 ** Calendar and diary
 
 ---
--- a/lisp/ChangeLog	Wed Aug 19 19:42:25 2009 +0000
+++ b/lisp/ChangeLog	Wed Aug 19 19:55:58 2009 +0000
@@ -1,6 +1,12 @@
+2009-08-19  Magnus Henoch  <magnus.henoch@gmail.com>
+
+	* log-edit.el (log-edit-strip-single-file-name): New var.
+	(log-edit-insert-changelog): Use it.
+
 2009-08-19  Stefan Monnier  <monnier@iro.umontreal.ca>
 
 	* subr.el (read-passwd): Use read-key so keypad keys work as well.
+	Bug#3287
 
 	* help.el (help-print-return-message): Rename from
 	print-help-return-message.
--- a/lisp/log-edit.el	Wed Aug 19 19:42:25 2009 +0000
+++ b/lisp/log-edit.el	Wed Aug 19 19:55:58 2009 +0000
@@ -148,6 +148,10 @@
   :type '(hook :options (log-edit-set-common-indentation
 			 log-edit-add-to-changelog)))
 
+(defcustom log-edit-strip-single-file-name t
+  "If non-nil, remove file name from single-file log entries."
+  :type 'boolean)
+
 (defvar cvs-changelog-full-paragraphs t)
 (make-obsolete-variable 'cvs-changelog-full-paragraphs
                         'log-edit-changelog-full-paragraphs
@@ -521,7 +525,7 @@
     (log-edit-insert-changelog-entries (log-edit-files)))
   (log-edit-set-common-indentation)
   (goto-char (point-min))
-  (when (looking-at "\\*\\s-+")
+  (when (and log-edit-strip-single-file-name (looking-at "\\*\\s-+"))
     (forward-line 1)
     (when (not (re-search-forward "^\\*\\s-+" nil t))
       (goto-char (point-min))