From 9e0cc6e686a69b95b2fe5d15e6d1850a2b7f27b1 Mon Sep 17 00:00:00 2001 From: "Richard M. Stallman" Date: Fri, 23 Jun 1995 15:50:17 +0000 Subject: [PATCH] (vc-backend-admin, vc-backend-checkin): Assume that comments are empty if they contain only white space. --- lisp/vc.el | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/lisp/vc.el b/lisp/vc.el index 8cd4a752a43..2629b9268e1 100644 --- a/lisp/vc.el +++ b/lisp/vc.el @@ -1545,7 +1545,7 @@ From a program, any arguments are passed to the `rcs2log' script." ((eq backend 'CVS) (vc-do-command 0 "cvs" file 'WORKFILE ;; CVS "add" - (and comment (not (string= comment "")) + (and comment (string-match "[^\t\n ]" comment) (concat "-m" comment))) ))) (message "Registering %s...done" file) @@ -1688,8 +1688,9 @@ From a program, any arguments are passed to the `rcs2log' script." ;; accordingly. (message "Checking in %s..." file) ;; "This log message intentionally left almost blank". - (and (or (not comment) (string= comment "")) - (setq comment "*** empty log message ***")) + ;; RCS 5.7 gripes about white-space-only comments too. + (or (and comment (string-match "[^\t\n ]" comment)) + (setq comment "*** empty log message ***")) (save-excursion ;; Change buffers to get local value of vc-checkin-switches. (set-buffer (or (get-file-buffer file) (current-buffer))) -- 2.39.2