comparison lisp/vc-bzr.el @ 96539:d9bc43f652b0

(vc-bzr-after-dir-status): Deal with execute bit changes.
author Dan Nicolaescu <dann@ics.uci.edu>
date Mon, 07 Jul 2008 16:34:14 +0000
parents 09da7727f35f
children 58215ab2e8e6
comparison
equal deleted inserted replaced
96538:187f69369145 96539:d9bc43f652b0
574 (concat "(" (symbol-name (or (vc-file-getprop file 'vc-bzr-state) 574 (concat "(" (symbol-name (or (vc-file-getprop file 'vc-bzr-state)
575 'edited)) ")") 575 'edited)) ")")
576 ;; else fall back to default vc.el representation 576 ;; else fall back to default vc.el representation
577 (vc-default-prettify-state-info 'Bzr file))) 577 (vc-default-prettify-state-info 'Bzr file)))
578 578
579 ;; XXX: this needs testing, it's probably incomplete. 579 ;; FIXME: this needs testing, it's probably incomplete.
580 (defun vc-bzr-after-dir-status (update-function) 580 (defun vc-bzr-after-dir-status (update-function)
581 (let ((status-str nil) 581 (let ((status-str nil)
582 (translation '(("+N" . added) 582 (translation '(("+N " . added)
583 ("-D" . removed) 583 ("-D " . removed)
584 (" M" . edited) 584 (" M " . edited) ;; file text modified
585 ;; XXX: what about ignored files? 585 (" *" . edited) ;; execute bit changed
586 (" D" . missing) 586 (" M*" . edited) ;; text modified + execute bit changed
587 ;; FIXME: what about ignored files?
588 (" D " . missing)
587 ;; For conflicts, should we list the .THIS/.BASE/.OTHER? 589 ;; For conflicts, should we list the .THIS/.BASE/.OTHER?
588 ("C " . conflict) 590 ("C " . conflict)
589 ("? " . unregistered) 591 ("? " . unregistered)
590 ;; Ignore "P " and "P." for pending patches. 592 ;; Ignore "P " and "P." for pending patches.
591 )) 593 ))
592 (translated nil) 594 (translated nil)
593 (result nil)) 595 (result nil))
594 (goto-char (point-min)) 596 (goto-char (point-min))
595 (while (not (eobp)) 597 (while (not (eobp))
596 (setq status-str 598 (setq status-str
597 (buffer-substring-no-properties (point) (+ (point) 2))) 599 (buffer-substring-no-properties (point) (+ (point) 3)))
598 (setq translated (cdr (assoc status-str translation))) 600 (setq translated (cdr (assoc status-str translation)))
599 ;; For conflicts the file appears twice in the listing: once 601 ;; For conflicts the file appears twice in the listing: once
600 ;; with the M flag and once with the C flag, so take care not 602 ;; with the M flag and once with the C flag, so take care not
601 ;; to add it twice to `result'. Ugly. 603 ;; to add it twice to `result'. Ugly.
602 (if (eq translated 'conflict) 604 (if (eq translated 'conflict)