Function: vc-print-root-log
vc-print-root-log is an autoloaded, interactive and byte-compiled
function defined in vc.el.gz.
Signature
(vc-print-root-log &optional LIMIT REVISION)
Documentation
Show in another window VC change history of the current VC controlled tree.
If LIMIT is non-nil, it should be a number specifying the maximum
number of revisions to show; the default is vc-log-show-limit.
When called interactively with a prefix argument, prompt for LIMIT, but
if the prefix argument is a number, use it as LIMIT.
A special case is when the prefix argument is 1: in this case
the command prompts for the id of a REVISION, and shows that revision
with its diffs (if the underlying VCS backend supports that).
Probably introduced at or before Emacs version 24.1.
Key Bindings
Source Code
;; Defined in /usr/src/emacs/lisp/vc/vc.el.gz
;;;###autoload
(defun vc-print-root-log (&optional limit revision)
"Show in another window VC change history of the current VC controlled tree.
If LIMIT is non-nil, it should be a number specifying the maximum
number of revisions to show; the default is `vc-log-show-limit'.
When called interactively with a prefix argument, prompt for LIMIT, but
if the prefix argument is a number, use it as LIMIT.
A special case is when the prefix argument is 1: in this case
the command prompts for the id of a REVISION, and shows that revision
with its diffs (if the underlying VCS backend supports that)."
(interactive
(cond
((eq current-prefix-arg 1)
(let* ((default (thing-at-point 'word t))
(revision (read-string (format-prompt "Revision to show" default)
nil nil default)))
(list 1 revision)))
((numberp current-prefix-arg)
(list current-prefix-arg))
(current-prefix-arg
(let ((lim (vc--read-limit)))
(list (and (plusp lim) lim))))
(t
(list (and (plusp vc-log-show-limit) vc-log-show-limit)))))
(vc--with-backend-in-rootdir "VC revision log"
(let* ((with-diff (and (eq limit 1) revision))
(vc-log-short-style (and (not with-diff) vc-log-short-style)))
(vc-print-log-internal backend (list rootdir) revision revision limit
(and with-diff 'with-diff))
;; We're looking at the root, so displaying " from <some-file>" in
;; the mode line isn't helpful.
(setq vc-parent-buffer-name nil))))