From: Stefan Monnier Date: Fri, 30 May 2008 16:21:49 +0000 (+0000) Subject: (vc-cvs-state-heuristic, vc-cvs-parse-status): Try and X-Git-Tag: emacs-pretest-23.0.90~5196 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=47dd5958df9455778bec7f772889cabc8614176a;p=emacs.git (vc-cvs-state-heuristic, vc-cvs-parse-status): Try and return `unregistered' when applicable. --- diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 59d10082e62..a4634a630e6 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,5 +1,8 @@ 2008-05-30 Stefan Monnier + * vc-cvs.el (vc-cvs-state-heuristic, vc-cvs-parse-status): Try and + return `unregistered' when applicable. + * emacs-lisp/checkdoc.el (checkdoc-this-string-valid-engine): Don't encourage naming variables with "-flag". @@ -295,7 +298,7 @@ * vc.el (vc-delete-file): Don't try to resynch the buffer. -2008-05-23 Paul R +2008-05-23 Paul Rivier * textmodes/reftex-vars.el (reftex-extra-bindings-prefix): New var. * textmodes/reftex.el (reftex-extra-bindings-map): New var. diff --git a/lisp/vc-cvs.el b/lisp/vc-cvs.el index 30f32dfc174..091c36c99cf 100644 --- a/lisp/vc-cvs.el +++ b/lisp/vc-cvs.el @@ -231,6 +231,7 @@ See also variable `vc-cvs-sticky-date-format-string'." (cond ((equal checkout-time lastmod) 'up-to-date) ((string= (vc-working-revision file) "0") 'added) + ((null checkout-time) 'unregistered) (t 'edited)))) (defun vc-cvs-working-revision (file) @@ -800,9 +801,8 @@ state." ((re-search-forward "\\=\\([^ \t]+\\)" nil t) (setq file (expand-file-name (match-string 1))) (vc-file-setprop file 'vc-backend 'CVS) - (if (not (re-search-forward "\\=[ \t]+Status: \\(.*\\)" nil t)) - (setq status "Unknown") - (setq status (match-string 1))) + (setq status(if (re-search-forward "\\=[ \t]+Status: \\(.*\\)" nil t) + (match-string 1) "Unknown")) (when (and full (re-search-forward "\\(RCS Version\\|RCS Revision\\|Repository revision\\):\ @@ -823,6 +823,7 @@ state." ((string-match "Locally Added" status) 'added) ((string-match "Locally Removed" status) 'removed) ((string-match "File had conflicts " status) 'conflict) + ((string-match "Unknown" status) 'unregistered) (t 'edited)))))))) (defun vc-cvs-after-dir-status (update-function)