# HG changeset patch # User Dan Nicolaescu # Date 1206078828 0 # Node ID 01d3fd1a2cfe5d18bb17514618576cef923c1d46 # Parent 87f463ae15300871ce92c8030139cf5169472929 * vc-hg.el (vc-hg-state): * vc-git.el (vc-git-state): * vc-cvs.el (vc-cvs-parse-status): * vc-bzr.el (vc-bzr-state): Return 'added when the file is in that state. diff -r 87f463ae1530 -r 01d3fd1a2cfe lisp/ChangeLog --- a/lisp/ChangeLog Fri Mar 21 01:49:18 2008 +0000 +++ b/lisp/ChangeLog Fri Mar 21 05:53:48 2008 +0000 @@ -1,3 +1,11 @@ +2008-03-21 Dan Nicolaescu + + * vc-hg.el (vc-hg-state): + * vc-git.el (vc-git-state): + * vc-cvs.el (vc-cvs-parse-status): + * vc-bzr.el (vc-bzr-state): Return 'added when the file is in that + state. + 2008-03-20 Stefan Monnier * progmodes/compile.el (compile): diff -r 87f463ae1530 -r 01d3fd1a2cfe lisp/vc-bzr.el --- a/lisp/vc-bzr.el Fri Mar 21 01:49:18 2008 +0000 +++ b/lisp/vc-bzr.el Fri Mar 21 05:53:48 2008 +0000 @@ -223,7 +223,7 @@ (if (cdr result) (message "Warnings in `bzr' output: %s" (cdr result))) (cdr (assq (car result) - '((added . edited) + '((added . added) (kindchanged . edited) (renamed . edited) (modified . edited) diff -r 87f463ae1530 -r 01d3fd1a2cfe lisp/vc-cvs.el --- a/lisp/vc-cvs.el Fri Mar 21 01:49:18 2008 +0000 +++ b/lisp/vc-cvs.el Fri Mar 21 05:53:48 2008 +0000 @@ -860,6 +860,7 @@ ((string-match "Locally Modified" status) 'edited) ((string-match "Needs Merge" status) 'needs-merge) ((string-match "Needs \\(Checkout\\|Patch\\)" status) 'needs-patch) + ((string-match "Locally Added" status) 'added) (t 'edited)))))))) (defun vc-cvs-dir-state-heuristic (dir) diff -r 87f463ae1530 -r 01d3fd1a2cfe lisp/vc-git.el --- a/lisp/vc-git.el Fri Mar 21 01:49:18 2008 +0000 +++ b/lisp/vc-git.el Fri Mar 21 05:53:48 2008 +0000 @@ -146,9 +146,9 @@ ;; FIXME: This can't set 'ignored yet (vc-git--call nil "add" "--refresh" "--" (file-relative-name file)) (let ((diff (vc-git--run-command-string file "diff-index" "-z" "HEAD" "--"))) - (if (and diff (string-match ":[0-7]\\{6\\} [0-7]\\{6\\} [0-9a-f]\\{40\\} [0-9a-f]\\{40\\} [ADMU]\0[^\0]+\0" + (if (and diff (string-match ":[0-7]\\{6\\} [0-7]\\{6\\} [0-9a-f]\\{40\\} [0-9a-f]\\{40\\} \\([ADMU]\\)\0[^\0]+\0" diff)) - 'edited + (if (string= (match-string 1 diff) "A") 'added 'edited) 'up-to-date))) (defun vc-git--ls-files-state (state &rest args) diff -r 87f463ae1530 -r 01d3fd1a2cfe lisp/vc-hg.el --- a/lisp/vc-hg.el Fri Mar 21 01:49:18 2008 +0000 +++ b/lisp/vc-hg.el Fri Mar 21 05:53:48 2008 +0000 @@ -173,7 +173,7 @@ (let ((state (aref out 0))) (cond ((eq state ?=) 'up-to-date) - ((eq state ?A) 'edited) + ((eq state ?A) 'added) ((eq state ?M) 'edited) ((eq state ?I) 'ignored) ((eq state ?R) 'unregistered)