vc-log-show-limit: Change default to 500, and the button to 4X

* lisp/vc/vc.el (vc-log-show-limit):
Change the default to 500 (bug#80037).
(vc-print-log-setup-buttons): Have the first button prompt and
propose 4X the current limit as the default.
(vc-print-fileset-branch-log):
Update the reference to the changed button text.

* lisp/vc/log-view.el (log-view-end-of-defun-1): Same.

* doc/emacs/maintaining.texi (VC Change Log): Also here.
This commit is contained in:
Dmitry Gutov 2026-02-14 02:46:32 +02:00
parent aa181cd352
commit a937396e76
3 changed files with 10 additions and 8 deletions

View file

@ -1327,7 +1327,7 @@ Because fetching many log entries can be slow, the
default. The variable @code{vc-log-show-limit} specifies this limit;
if you set the value to zero, that removes the limit. You can also
increase the number of revisions shown in an existing
@file{*vc-change-log*} buffer by clicking on the @samp{Show 2X
@file{*vc-change-log*} buffer by clicking on the @samp{Show 4X
entries} or @samp{Show unlimited entries} buttons at the end of the
buffer. However, RCS, SCCS, CVS, and SRC do not support this feature.

View file

@ -599,7 +599,7 @@ It assumes that a log entry starts with a line matching
(goto-char (match-beginning 0))))
;; Don't advance past the end buttons inserted by
;; `vc-print-log-setup-buttons'.
((looking-back "Show 2X entries Show unlimited entries"
((looking-back "Show 4X entries Show unlimited entries"
(line-beginning-position))
(setq looping nil)
(forward-line -1))

View file

@ -1023,7 +1023,7 @@ for the backend you use."
(repeat :tag "Argument List" :value ("") string))
:version "25.1")
(defcustom vc-log-show-limit 2000
(defcustom vc-log-show-limit 500
"Limit the number of items shown by the VC log commands.
Zero means unlimited.
Not all VC backends are able to support this feature."
@ -4046,11 +4046,12 @@ or if PL-RETURN is `limit-unsupported'."
(goto-char (point-max))
(insert "\n")
(insert-text-button
"Show 2X entries"
"Show 4X entries"
'action (lambda (&rest _ignore)
(vc-print-log-internal
log-view-vc-backend log-view-vc-fileset
working-revision nil (* 2 limit)))
(let ((new-limit (read-number "How many: " (* 4 limit))))
(vc-print-log-internal
log-view-vc-backend log-view-vc-fileset
working-revision nil new-limit)))
'help-echo
"Show the log again, and double the number of log entries shown")
(insert " ")
@ -4354,7 +4355,8 @@ can specify a revision ID instead of a branch name to produce a log
starting at that revision. Tags and remote references also work."
;; Currently the prefix argument is conserved. Possibly it could be
;; used to prompt for a LIMIT argument like \\`C-x v l' has. Though
;; now we have "Show 2X entries" and "Show unlimited entries" that
;; now we have "Show 4X entries" and "Show unlimited entries" that
;; might be a waste of the prefix argument to this command. --spwhitton
(interactive (list (vc--read-branch-to-log t)))
(let ((fileset (vc-deduce-fileset t)))