aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDan Nicolaescu2010-01-03 20:35:21 -0800
committerDan Nicolaescu2010-01-03 20:35:21 -0800
commit137d88ca4b508421c511875801dcbff81588979c (patch)
treebc796a6b64874ef2223099a7d2fec085a1c689c8
parent777013f2bf9f548902c03ffbca0e98507d12ee64 (diff)
downloademacs-137d88ca4b508421c511875801dcbff81588979c.tar.gz
emacs-137d88ca4b508421c511875801dcbff81588979c.zip
(vc-bzr-state-heuristic): Make it work for lightweight
checkouts. (Bug#618)
-rw-r--r--lisp/ChangeLog5
-rw-r--r--lisp/vc-bzr.el21
2 files changed, 20 insertions, 6 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog
index cfde9093e75..82061b6bb65 100644
--- a/lisp/ChangeLog
+++ b/lisp/ChangeLog
@@ -1,3 +1,8 @@
12010-01-04 Dan Nicolaescu <dann@ics.uci.edu>
2
3 * vc-bzr.el (vc-bzr-state-heuristic): Make it work for lightweight
4 checkouts. (Bug#618)
5
12010-01-02 Chong Yidong <cyd@stupidchicken.com> 62010-01-02 Chong Yidong <cyd@stupidchicken.com>
2 7
3 * net/browse-url.el (browse-url-encode-url): Don't escape commas. 8 * net/browse-url.el (browse-url-encode-url): Don't escape commas.
diff --git a/lisp/vc-bzr.el b/lisp/vc-bzr.el
index fff4eca57fa..80aa420aa9e 100644
--- a/lisp/vc-bzr.el
+++ b/lisp/vc-bzr.el
@@ -176,13 +176,13 @@ Invoke the bzr command adding `BZR_PROGRESS_BAR=none' and
176 "\0" 176 "\0"
177 "[^\0]*\0" ;id? 177 "[^\0]*\0" ;id?
178 "\\([^\0]*\\)\0" ;"a/f/d", a=removed? 178 "\\([^\0]*\\)\0" ;"a/f/d", a=removed?
179 "[^\0]*\0" ;sha1 (empty if conflicted)? 179 "\\([^\0]*\\)\0" ;sha1 (empty if conflicted)?
180 "\\([^\0]*\\)\0" ;size? 180 "\\([^\0]*\\)\0" ;size?p
181 "[^\0]*\0" ;"y/n", executable? 181 "[^\0]*\0" ;"y/n", executable?
182 "[^\0]*\0" ;? 182 "[^\0]*\0" ;?
183 "\\([^\0]*\\)\0" ;"a/f/d" a=added? 183 "\\([^\0]*\\)\0" ;"a/f/d" a=added?
184 "\\([^\0]*\\)\0" ;sha1 again? 184 "\\([^\0]*\\)\0" ;sha1 again?
185 "[^\0]*\0" ;size again? 185 "\\([^\0]*\\)\0" ;size again?
186 "[^\0]*\0" ;"y/n", executable again? 186 "[^\0]*\0" ;"y/n", executable again?
187 "[^\0]*\0" ;last revid? 187 "[^\0]*\0" ;last revid?
188 ;; There are more fields when merges are pending. 188 ;; There are more fields when merges are pending.
@@ -194,11 +194,20 @@ Invoke the bzr command adding `BZR_PROGRESS_BAR=none' and
194 ;; conflict markers). 194 ;; conflict markers).
195 (cond 195 (cond
196 ((eq (char-after (match-beginning 1)) ?a) 'removed) 196 ((eq (char-after (match-beginning 1)) ?a) 'removed)
197 ((eq (char-after (match-beginning 3)) ?a) 'added) 197 ((eq (char-after (match-beginning 4)) ?a) 'added)
198 ((and (eq (string-to-number (match-string 2)) 198 ((or (and (eq (string-to-number (match-string 3))
199 (nth 7 (file-attributes file))) 199 (nth 7 (file-attributes file)))
200 (equal (match-string 4) 200 (equal (match-string 5)
201 (vc-bzr-sha1 file))) 201 (vc-bzr-sha1 file)))
202 (and
203 ;; It looks like for lightweight
204 ;; checkouts \2 is empty and we need to
205 ;; look for size in \6.
206 (eq (match-beginning 2) (match-end 2))
207 (eq (string-to-number (match-string 6))
208 (nth 7 (file-attributes file)))
209 (equal (match-string 5)
210 (vc-bzr-sha1 file))))
202 'up-to-date) 211 'up-to-date)
203 (t 'edited)) 212 (t 'edited))
204 'unregistered)))) 213 'unregistered))))