[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] /srv/bzr/emacs/trunk r102900: vc-svn fix for bug#7861.
From: |
Glenn Morris |
Subject: |
[Emacs-diffs] /srv/bzr/emacs/trunk r102900: vc-svn fix for bug#7861. |
Date: |
Tue, 18 Jan 2011 19:49:00 -0800 |
User-agent: |
Bazaar (2.0.3) |
------------------------------------------------------------
revno: 102900
committer: Glenn Morris <address@hidden>
branch nick: trunk
timestamp: Tue 2011-01-18 19:49:00 -0800
message:
vc-svn fix for bug#7861.
* lisp/vc/vc-svn.el (vc-svn-after-dir-status, vc-svn-parse-status):
Also check the property status.
modified:
lisp/ChangeLog
lisp/vc/vc-svn.el
=== modified file 'lisp/ChangeLog'
--- a/lisp/ChangeLog 2011-01-18 15:33:24 +0000
+++ b/lisp/ChangeLog 2011-01-19 03:49:00 +0000
@@ -1,3 +1,8 @@
+2011-01-19 Glenn Morris <address@hidden>
+
+ * vc/vc-svn.el (vc-svn-after-dir-status, vc-svn-parse-status):
+ Also check the property status. (Bug#7861)
+
2011-01-18 Michael Albinus <address@hidden>
* net/tramp.el (tramp-debug-message): Extend function exclude
=== modified file 'lisp/vc/vc-svn.el'
--- a/lisp/vc/vc-svn.el 2011-01-15 23:16:57 +0000
+++ b/lisp/vc/vc-svn.el 2011-01-19 03:49:00 +0000
@@ -171,15 +171,18 @@
(?? . unregistered)
;; This is what vc-svn-parse-status does.
(?~ . edited)))
- (re (if remote "^\\(.\\)......? \\([ *]\\) +\\(?:[-0-9]+\\)?
\\(.*\\)$"
- ;; Subexp 2 is a dummy in this case, so the numbers match.
- "^\\(.\\)....\\(.\\) \\(.*\\)$"))
+ (re (if remote "^\\(.\\)\\(.\\).....? \\([ *]\\) +\\(?:[-0-9]+\\)?
\\(.*\\)$"
+ ;; Subexp 3 is a dummy in this case, so the numbers match.
+ "^\\(.\\)\\(.\\)...\\(.\\) \\(.*\\)$"))
result)
(goto-char (point-min))
(while (re-search-forward re nil t)
(let ((state (cdr (assq (aref (match-string 1) 0) state-map)))
- (filename (match-string 3)))
- (and remote (string-equal (match-string 2) "*")
+ (propstat (cdr (assq (aref (match-string 2) 0) state-map)))
+ (filename (match-string 4)))
+ (if (memq propstat '(conflict edited))
+ (setq state propstat))
+ (and remote (string-equal (match-string 3) "*")
;; FIXME are there other possible combinations?
(cond ((eq state 'edited) (setq state 'needs-merge))
((not state) (setq state 'needs-update))))
@@ -643,7 +646,7 @@
"Parse output of \"svn status\" command in the current buffer.
Set file properties accordingly. Unless FILENAME is non-nil, parse only
information about FILENAME and return its status."
- (let (file status)
+ (let (file status propstat)
(goto-char (point-min))
(while (re-search-forward
;; Ignore the files with status X.
@@ -653,7 +656,9 @@
(setq file (or filename
(expand-file-name
(buffer-substring (point) (line-end-position)))))
- (setq status (char-after (line-beginning-position)))
+ (setq status (char-after (line-beginning-position))
+ ;; Status of the item's properties ([ MC]).
+ propstat (char-after (1+ (line-beginning-position))))
(if (eq status ??)
(vc-file-setprop file 'vc-state 'unregistered)
;; Use the last-modified revision, so that searching in vc-print-log
@@ -664,7 +669,7 @@
(vc-file-setprop
file 'vc-state
(cond
- ((eq status ?\ )
+ ((and (eq status ?\ ) (eq propstat ?\ ))
(if (eq (char-after (match-beginning 1)) ?*)
'needs-update
(vc-file-setprop file 'vc-checkout-time
@@ -675,9 +680,11 @@
(vc-file-setprop file 'vc-working-revision "0")
(vc-file-setprop file 'vc-checkout-time 0)
'added)
- ((eq status ?C)
+ ;; Conflict in contents or properties.
+ ((or (eq status ?C) (eq propstat ?C))
(vc-file-setprop file 'vc-state 'conflict))
- ((eq status '?M)
+ ;; Modified contents or properties.
+ ((or (eq status ?M) (eq propstat ?M))
(if (eq (char-after (match-beginning 1)) ?*)
'needs-merge
'edited))
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Emacs-diffs] /srv/bzr/emacs/trunk r102900: vc-svn fix for bug#7861.,
Glenn Morris <=