diff lisp/vc-svn.el @ 87477:b5060e79eb98

* vc-svn.el (vc-svn-parse-status): Recognize 'added, 'removed, and 'unregistered states. * vc-hooks.el (vc-state): Added 'removed state to documentation. * vc-hg (vc-hg-parse-status): Recognize 'added, 'removed, and 'up-to-date state. Deal with the possibility that C for clean might change to "=" in the next point release. * vc-git.el (vc-git-parse-status): Recognize 'removed. * vc.el (header comment): Better description of new dir-state. (vc-compatible-state): Defines which states are mutually compatible; usable with 'edited as a test for which can be committed on. (vc-dired-hook): Turn off undo in the VC-Dired buffer, a speed tweak. (vc-default-dired-state-info): Display 'removed state. * vc-bzr.el (vc-bzr-dir-state): Recognize 'added.
author Eric S. Raymond <esr@snark.thyrsus.com>
date Sat, 29 Dec 2007 13:20:49 +0000
parents 71fc7b1db920
children 4146f1cc135e
line wrap: on
line diff
--- a/lisp/vc-svn.el	Sat Dec 29 12:59:09 2007 +0000
+++ b/lisp/vc-svn.el	Sat Dec 29 13:20:49 2007 +0000
@@ -543,15 +543,16 @@
   (let (file status)
     (goto-char (point-min))
     (while (re-search-forward
-            ;; Ignore the files with status in [IX?].
-	    "^[ ACDGMR!~][ MC][ L][ +][ S]..\\([ *]\\) +\\([-0-9]+\\) +\\([0-9?]+\\) +\\([^ ]+\\) +" nil t)
+            ;; Ignore the files with status X.
+	    "^[ ACDGIMR!?~][ MC][ L][ +][ S]..\\([ *]\\) +\\([-0-9]+\\) +\\([0-9?]+\\) +\\([^ ]+\\) +" nil t)
       ;; If the username contains spaces, the output format is ambiguous,
       ;; so don't trust the output's filename unless we have to.
       (setq file (or filename
                      (expand-file-name
                       (buffer-substring (point) (line-end-position)))))
       (setq status (char-after (line-beginning-position)))
-      (unless (eq status ??)
+      (if (eq status ??)
+	  (vc-file-setprop file 'vc-state 'unregistered)
 	;; `vc-BACKEND-registered' must not set vc-backend,
 	;; which is instead set in vc-registered.
 	(unless filename (vc-file-setprop file 'vc-backend 'SVN))
@@ -573,15 +574,15 @@
 	   ;; If the file was actually copied, (match-string 2) is "-".
 	   (vc-file-setprop file 'vc-working-revision "0")
 	   (vc-file-setprop file 'vc-checkout-time 0)
-	   'edited)
+	   'added)
 	  ((memq status '(?M ?C))
 	   (if (eq (char-after (match-beginning 1)) ?*)
 	       'needs-merge
 	     'edited))
 	  ((eq status ?I)
 	   (vc-file-setprop file 'vc-state 'ignored))
-	  ((eq status ??)
-	   (vc-file-setprop file 'vc-state 'unregistered))
+	  ((eq status ?R)
+	   (vc-file-setprop file 'vc-state 'removed))
 	  (t 'edited)))))
     (if filename (vc-file-getprop filename 'vc-state))))