From 3d6e95e7673bf1352a439cdd705eae00e65a0542 Mon Sep 17 00:00:00 2001 From: Juri Linkov Date: Thu, 19 Dec 2013 23:10:41 +0200 Subject: [PATCH] * lisp/vc/log-edit.el (log-edit-insert-filenames-without-changelog): New function. (log-edit-hook): Add it to :options. Fixes: debbugs:16170 --- lisp/ChangeLog | 6 ++++++ lisp/vc/log-edit.el | 16 ++++++++++++++++ 2 files changed, 22 insertions(+) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 636617595cb..6db17ab66c6 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,9 @@ +2013-12-19 Juri Linkov + + * vc/log-edit.el (log-edit-insert-filenames-without-changelog): + New function. + (log-edit-hook): Add it to :options. (Bug#16170) + 2013-12-19 Juri Linkov * simple.el (eval-expression-print-format): Don't check for diff --git a/lisp/vc/log-edit.el b/lisp/vc/log-edit.el index 2ee60a872e4..791215b8000 100644 --- a/lisp/vc/log-edit.el +++ b/lisp/vc/log-edit.el @@ -137,6 +137,7 @@ its SETUP argument is non-nil." log-edit-insert-cvs-template log-edit-insert-changelog log-edit-insert-filenames + log-edit-insert-filenames-without-changelog log-edit-show-files))) (defcustom log-edit-mode-hook (if (boundp 'vc-log-mode-hook) vc-log-mode-hook) @@ -664,6 +665,21 @@ can thus take some time." (insert "Affected files: \n" (mapconcat 'identity (log-edit-files) " \n"))) +(defun log-edit-insert-filenames-without-changelog () + "Insert the list of files that have no ChangeLog message." + (interactive) + (let ((files + (delq nil + (mapcar + (lambda (file) + (unless (or (cdr-safe (log-edit-changelog-entries file)) + (equal (file-name-nondirectory file) "ChangeLog")) + file)) + (log-edit-files))))) + (when files + (goto-char (point-max)) + (insert (mapconcat 'identity files ", ") ": ")))) + (defun log-edit-add-to-changelog () "Insert this log message into the appropriate ChangeLog file." (interactive) -- 2.39.2