diff options
author | Stefan Monnier <[email protected]> | 2007-06-20 16:32:09 +0000 |
---|---|---|
committer | Stefan Monnier <[email protected]> | 2007-06-20 16:32:09 +0000 |
commit | 37a5e97abf2dfdddcb80330d34fba1eeded7a494 (patch) | |
tree | 1d5ed09046aa6b7838c4205647b24e9be325cc6b /lisp | |
parent | 858a9480ffdda7c5b0204ab00dfe71121e88b902 (diff) |
(vc-default-log-view-mode): New function.
(vc-print-log): Add new `log-view-mode' VC operation.
Diffstat (limited to 'lisp')
-rw-r--r-- | lisp/ChangeLog | 5 | ||||
-rw-r--r-- | lisp/vc.el | 13 |
2 files changed, 16 insertions, 2 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog index d446ef9392..7ad751b047 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2007-06-20 Stefan Monnier <[email protected]> + + * vc.el (vc-default-log-view-mode): New function. + (vc-print-log): Add new `log-view-mode' VC operation. + 2007-06-20 Juanma Barranquero <[email protected]> * ido.el (ido-find-file-in-dir): Don't signal an error for diff --git a/lisp/vc.el b/lisp/vc.el index d5c53a15a7..19e428d90a 100644 --- a/lisp/vc.el +++ b/lisp/vc.el @@ -105,7 +105,9 @@ ;; ;; * registered (file) ;; -;; Return non-nil if FILE is registered in this backend. +;; Return non-nil if FILE is registered in this backend. Both this +;; function as well as `state' should be careful to fail gracefully in the +;; event that the backend executable is absent. ;; ;; * state (file) ;; @@ -270,6 +272,12 @@ ;; Insert the revision log of FILE into BUFFER, or the *vc* buffer ;; if BUFFER is nil. ;; +;; - log-view-mode () +;; +;; Mode to use for the output of print-log. This defaults to +;; `log-view-mode' and is expected to be changed (if at all) to a derived +;; mode of `log-view-mode'. +;; ;; - show-log-entry (version) ;; ;; If provided, search the log entry for VERSION in the current buffer, @@ -2453,7 +2461,7 @@ If FOCUS-REV is non-nil, leave the point at that revision." (pop-to-buffer (current-buffer)) (vc-exec-after `(let ((inhibit-read-only t)) - (log-view-mode) + (vc-call-backend ',(vc-backend file) 'log-view-mode) (goto-char (point-max)) (forward-line -1) (while (looking-at "=*\n") (delete-char (- (match-end 0) (match-beginning 0))) @@ -2468,6 +2476,7 @@ If FOCUS-REV is non-nil, leave the point at that revision." ',focus-rev) (set-buffer-modified-p nil))))) +(defun vc-default-log-view-mode (backend) (log-view-mode)) (defun vc-default-show-log-entry (backend rev) (with-no-warnings (log-view-goto-rev rev))) |