1
Fork 0
mirror of git://git.sv.gnu.org/emacs.git synced 2026-02-12 02:40:34 -08:00

* vc-bzr.el (vc-bzr-root): Cache the output of shell command execution.

This commit is contained in:
Masatake YAMATO 2007-06-15 19:40:47 +00:00
parent 1bd8df7efa
commit b32ce4c33a
2 changed files with 10 additions and 3 deletions

View file

@ -1,6 +1,9 @@
2007-06-15 Masatake YAMATO <jet@gyve.org>
* vc.el (vc-dired-hook): check the backend returned from
* vc-bzr.el (vc-bzr-root): Cache the output of shell command
execution.
* vc.el (vc-dired-hook): Check the backend returned from
`vc-responsible-backend' can really handle `subdir'.
2007-06-15 Chong Yidong <cyd@stupidchicken.com>

View file

@ -463,8 +463,12 @@ Return nil if current line isn't annotated."
;; if there are any symbolic links.
(defun vc-bzr-root (dir)
"Return the root directory of the bzr repository containing DIR."
(substring
(shell-command-to-string (concat vc-bzr-program " root " dir)) 0 -1))
;; Cache technique copied from vc-arch.el.
(or (vc-file-getprop dir 'bzr-root)
(vc-file-setprop
dir 'bzr-root
(substring
(shell-command-to-string (concat vc-bzr-program " root " dir)) 0 -1))))
;; TODO: it would be nice to mark the conflicted files in VC Dired,
;; and implement a command to run ediff and `bzr resolve' once the