Rename VC outgoing and incoming log commands to include "-root-"

* lisp/vc/vc.el (vc-log-incoming, vc-log-outgoing): Rename ...
(vc-root-log-incoming, vc-root-log-outgoing): ... to these.  All
uses changed.  Leave behind obsolete function aliases.
* lisp/emacs-lisp/package-vc.el (package-vc-log-incoming):
Rename ...
(package-vc-root-log-incoming): ... to this.  All uses changed.
Leave behind obsolete function alias.
This commit is contained in:
Sean Whitton 2026-01-14 12:48:02 +00:00
parent 65655ccfae
commit aa6e42f18b
7 changed files with 67 additions and 54 deletions

View file

@ -1066,12 +1066,12 @@ Display the change history for the current repository on another branch
@item C-x v I
Display log entries for the changes that a ``pull'' operation will
retrieve (@code{vc-log-incoming}).
retrieve (@code{vc-root-log-incoming}).
@vindex vc-use-incoming-outgoing-prefixes
If you customize @code{vc-use-incoming-outgoing-prefixes} to
non-@code{nil}, @kbd{C-x v I} becomes a prefix key, and
@code{vc-log-incoming} becomes bound to @kbd{C-x v I L}.
@code{vc-root-log-incoming} becomes bound to @kbd{C-x v I L}.
@item M-x vc-root-diff-incoming
Display a diff of all changes that a pull operation will retrieve.
@ -1088,11 +1088,11 @@ non-@code{nil}, this command becomes available on @kbd{C-x v I =}.
@item C-x v O
Display log entries for the changes that will be sent by the next
``push'' operation (@code{vc-log-outgoing}).
``push'' operation (@code{vc-root-log-outgoing}).
If you customize @code{vc-use-incoming-outgoing-prefixes} to
non-@code{nil}, @kbd{C-x v O} becomes a prefix key, and
@code{vc-log-outgoing} becomes bound to @kbd{C-x v O L}.
@code{vc-root-log-outgoing} becomes bound to @kbd{C-x v O L}.
@item M-x vc-root-diff-outgoing
Display a diff of all changes that will be sent by the next push
@ -1188,31 +1188,31 @@ or the remote branch references supported by Git.
@kindex C-x v I
@kindex C-x v O
@findex vc-log-incoming
@findex vc-log-outgoing
@findex vc-root-log-incoming
@findex vc-root-log-outgoing
On a decentralized version control system, the @kbd{C-x v I}
(@code{vc-log-incoming}) command displays a log buffer showing the
(@code{vc-root-log-incoming}) command displays a log buffer showing the
changes that will be applied the next time you run the version control
system's pull command to get new revisions from another remote location
(@pxref{Pulling / Pushing}). This other remote location is the default
one from which changes are pulled, as defined by the version control
system; with a prefix argument, @code{vc-log-incoming} prompts for a
particular remote location. Similarly, @kbd{C-x v O}
(@code{vc-log-outgoing}) shows the changes that will be sent to another
remote location, the next time you run the push command; with a prefix
argument, it prompts for a particular destination that in case of some
version control system can be a branch name.
system; with a prefix argument, @code{vc-root-log-incoming} prompts for
a particular remote location. Similarly, @kbd{C-x v O}
(@code{vc-root-log-outgoing}) shows the changes that will be sent to
another remote location, the next time you run the push command; with a
prefix argument, it prompts for a particular destination that in case of
some version control system can be a branch name.
@findex vc-root-diff-incoming
@findex vc-root-diff-outgoing
The closely related commands @code{vc-root-diff-incoming} and
@code{vc-root-diff-outgoing} are the diff analogues of
@code{vc-log-incoming} and @code{vc-log-outgoing}. These display diff
buffers reporting the changes that would be pulled or pushed. You can
use a prefix argument here too to specify a particular remote location.
@code{vc-root-diff-outgoing} is useful as a way to preview your push and
quickly check that all and only the changes you intended to include were
committed and will be pushed.
@code{vc-root-log-incoming} and @code{vc-root-log-outgoing}. These
display diff buffers reporting the changes that would be pulled or
pushed. You can use a prefix argument here too to specify a particular
remote location. @code{vc-root-diff-outgoing} is useful as a way to
preview your push and quickly check that all and only the changes you
intended to include were committed and will be pushed.
@findex vc-diff-incoming
@findex vc-diff-outgoing
@ -1562,8 +1562,8 @@ repository, such as the name of the backend in use and the working
directory. In addition, for decentralized VCS, if you have outgoing
commits (@pxref{VC Change Log}), Emacs displays a line @w{"Outgoing : N
unpushed revisions"} where @var{N} is a number. You can click on this
text to execute the @code{vc-log-outgoing} command (@pxref{VC Change
Log}).
text to execute the @code{vc-root-log-outgoing} command (@pxref{VC
Change Log}).
@vindex vc-dir-show-outgoing-count
Emacs tries to use cached information to determine the number of
@ -1840,9 +1840,9 @@ with Git, and @kbd{hg push} with Mercurial. The default commands
always push to the repository in the default location determined by
the version control system from your branch configuration.
Prior to pushing, you can use @kbd{C-x v O} (@code{vc-log-outgoing})
to view a log buffer of the changes to be sent upstream. @xref{VC
Change Log}.
Prior to pushing, you can use @kbd{C-x v O}
(@code{vc-root-log-outgoing}) to view a log buffer of the changes to be
sent upstream. @xref{VC Change Log}.
@cindex bound branch (Bazaar VCS)
This command is currently supported only by Bazaar, Git, and Mercurial.
@ -1876,9 +1876,9 @@ it into the current branch. With Mercurial, it calls @kbd{hg pull
-u} to fetch changesets from the default remote repository and update
the working directory.
Prior to pulling, you can use @kbd{C-x v I} (@code{vc-log-incoming})
to view a log buffer of the changes to be applied. @xref{VC Change
Log}.
Prior to pulling, you can use @kbd{C-x v I}
(@code{vc-root-log-incoming}) to view a log buffer of the changes to be
applied. @xref{VC Change Log}.
With a centralized version control system like CVS, @kbd{C-x v +}
updates the current VC fileset from the repository.

View file

@ -2668,8 +2668,8 @@ relevant buffers before generating the contents of a VC Directory buffer
*** New commands to report incoming and outgoing diffs.
'vc-root-diff-incoming' and 'vc-root-diff-outgoing' report diffs of all
the changes that would be pulled and would be pushed, respectively.
They are the diff analogues of the existing commands 'vc-log-incoming'
and 'vc-log-outgoing'.
They are the diff analogues of the existing commands
'vc-root-log-incoming' and 'vc-root-log-outgoing'.
In particular, 'vc-root-diff-outgoing' is useful as a way to preview
your push and ensure that all and only the changes you intended to
@ -2692,9 +2692,9 @@ If this is customized to non-nil, 'C-x v I' and 'C-x v O' become prefix
commands, such that the new incoming and outgoing commands have global
bindings:
- 'C-x v I L' is bound to 'vc-log-incoming'
- 'C-x v I L' is bound to 'vc-root-log-incoming'
- 'C-x v I D' is bound to 'vc-root-diff-incoming'
- 'C-x v O L' is bound to 'vc-log-outgoing'
- 'C-x v O L' is bound to 'vc-root-log-outgoing'
- 'C-x v O D' is bound to 'vc-root-diff-outgoing'.
+++

View file

@ -1086,13 +1086,17 @@ See also `vc-prepare-patch'."
(vc-prepare-patch (package-maintainers pkg-desc t)
subject revisions)))
(defun package-vc-log-incoming (pkg-desc)
"Call `vc-log-incoming' for the package PKG-DESC."
(defun package-vc-root-log-incoming (pkg-desc)
"Call `vc-root-log-incoming' for the package PKG-DESC."
(interactive
(list (package-vc--read-package-desc "Incoming log for package: " t)))
(let ((default-directory (package-vc--checkout-dir pkg-desc))
(vc-deduce-backend-nonvc-modes t))
(call-interactively #'vc-log-incoming)))
(call-interactively #'vc-root-log-incoming)))
(define-obsolete-function-alias
'package-vc-log-incoming
#'package-vc-root-log-incoming
"31.1")
(provide 'package-vc)
;;; package-vc.el ends here

View file

@ -294,10 +294,10 @@ That is, refreshing the VC-Dir buffer also hides `up-to-date' and
'(menu-item "Compare with Base Version" vc-diff
:help "Compare file set with the base version"))
(define-key map [logo]
'(menu-item "Show Outgoing Log" vc-log-outgoing
'(menu-item "Show Outgoing Log" vc-root-log-outgoing
:help "Show a log of changes that will be sent with a push operation"))
(define-key map [logi]
'(menu-item "Show Incoming Log" vc-log-incoming
'(menu-item "Show Incoming Log" vc-root-log-incoming
:help "Show a log of changes that will be received with a pull operation"))
(define-key map [log]
'(menu-item "Show History" vc-print-log
@ -354,8 +354,8 @@ That is, refreshing the VC-Dir buffer also hides `up-to-date' and
(define-key map "P" #'vc-push) ;; C-x v P
(define-key map "l" #'vc-print-log) ;; C-x v l
(define-key map "L" #'vc-print-root-log) ;; C-x v L
(define-key map "I" #'vc-log-incoming) ;; C-x v I
(define-key map "O" #'vc-log-outgoing) ;; C-x v O
(define-key map "I" #'vc-root-log-incoming) ;; C-x v I
(define-key map "O" #'vc-root-log-outgoing) ;; C-x v O
;; More confusing than helpful, probably
;;(define-key map "R" #'vc-revert) ;; u is taken by vc-dir-unmark.
;;(define-key map "A" #'vc-annotate) ;; g is taken by revert-buffer
@ -1335,7 +1335,7 @@ the *vc-dir* buffer.
(defvar-keymap vc-dir-outgoing-revisions-map
:doc "Local keymap for viewing outgoing revisions."
"<down-mouse-1>" #'vc-log-outgoing)
"<down-mouse-1>" #'vc-root-log-outgoing)
(defcustom vc-dir-show-outgoing-count t
"Whether to display the number of unpushed revisions in VC-Dir.
@ -1386,7 +1386,7 @@ specific headers."
'mouse-face 'highlight
'keymap vc-dir-outgoing-revisions-map
'help-echo "\\<vc-dir-outgoing-revisions-map>\
\\[vc-log-outgoing]: List outgoing revisions")
\\[vc-root-log-outgoing]: List outgoing revisions")
"\n"))))
(defun vc-dir-refresh-files (files)

View file

@ -1014,8 +1014,8 @@ In the latter case, VC mode is deactivated for this buffer."
"i" #'vc-register
"l" #'vc-print-log
"L" #'vc-print-root-log
"I" #'vc-log-incoming
"O" #'vc-log-outgoing
"I" #'vc-root-log-incoming
"O" #'vc-root-log-outgoing
"M L" #'vc-log-mergebase
"M D" #'vc-diff-mergebase
"o =" #'vc-diff-outgoing-base
@ -1044,11 +1044,11 @@ In the latter case, VC mode is deactivated for this buffer."
(define-key ctl-x-map "v" 'vc-prefix-map)
(defvar-keymap vc-incoming-prefix-map
"L" #'vc-log-incoming
"L" #'vc-root-log-incoming
"=" #'vc-diff-incoming
"D" #'vc-root-diff-incoming)
(defvar-keymap vc-outgoing-prefix-map
"L" #'vc-log-outgoing
"L" #'vc-root-log-outgoing
"=" #'vc-diff-outgoing
"D" #'vc-root-diff-outgoing)
@ -1056,9 +1056,10 @@ In the latter case, VC mode is deactivated for this buffer."
"Whether \\`C-x v I' and \\`C-x v O' are prefix commands.
Historically Emacs bound \\`C-x v I' and \\`C-x v O' directly to
commands. That is still the default. If this option is customized to
non-nil, these key sequences becomes prefix commands. `vc-log-incoming'
moves to \\`C-x v I L', `vc-log-outgoing' moves to \\`C-x v O L', and
other commands receive global bindings where they had none before."
non-nil, these key sequences becomes prefix commands.
`vc-root-log-incoming' moves to \\`C-x v I L', `vc-root-log-outgoing'
moves to \\`C-x v O L', and other commands receive global bindings where
they had none before."
:type 'boolean
:version "31.1"
:set (lambda (symbol value)
@ -1070,8 +1071,8 @@ other commands receive global bindings where they had none before."
(keymap-set map "I" vc-incoming-prefix-map)
(keymap-set map "O" vc-outgoing-prefix-map))
(dolist (map maps)
(keymap-set map "I" #'vc-log-incoming)
(keymap-set map "O" #'vc-log-outgoing))))
(keymap-set map "I" #'vc-root-log-incoming)
(keymap-set map "O" #'vc-root-log-outgoing))))
(set-default symbol value)))
(defvar vc-menu-map
@ -1122,10 +1123,10 @@ other commands receive global bindings where they had none before."
'(menu-item "Update ChangeLog" vc-update-change-log
:help "Find change log file and add entries from recent version control logs"))
(define-key map [vc-log-out]
'(menu-item "Show Outgoing Log" vc-log-outgoing
'(menu-item "Show Outgoing Log" vc-root-log-outgoing
:help "Show a log of changes that will be sent with a push operation"))
(define-key map [vc-log-in]
'(menu-item "Show Incoming Log" vc-log-incoming
'(menu-item "Show Incoming Log" vc-root-log-incoming
:help "Show a log of changes that will be received with a pull operation"))
(define-key map [vc-print-log]
'(menu-item "Show History" vc-print-log

View file

@ -4150,7 +4150,7 @@ starting at that revision. Tags and remote references also work."
(user-error "No incoming revision -- local-only branch?")))))
;;;###autoload
(defun vc-log-incoming (&optional upstream-location)
(defun vc-root-log-incoming (&optional upstream-location)
"Show log of changes that will be received with pull from UPSTREAM-LOCATION.
When unspecified UPSTREAM-LOCATION is the place \\[vc-update] would pull
from. When called interactively with a prefix argument, prompt for
@ -4160,6 +4160,10 @@ can be a remote branch name."
(vc--with-backend-in-rootdir "VC root-log"
(vc-incoming-outgoing-internal backend upstream-location
"*vc-incoming*" 'log-incoming)))
;; We plan to reuse the name `vc-log-incoming' for the fileset-specific
;; command in Emacs 32.1. --spwhitton
(define-obsolete-function-alias 'vc-log-incoming #'vc-root-log-incoming
"31.1")
(defun vc-default-log-incoming (backend buffer upstream-location)
(let ((incoming (vc--incoming-revision backend upstream-location
@ -4170,7 +4174,7 @@ can be a remote branch name."
(vc-call-backend backend 'mergebase incoming))))
;;;###autoload
(defun vc-log-outgoing (&optional upstream-location)
(defun vc-root-log-outgoing (&optional upstream-location)
"Show log of changes that will be sent with a push to UPSTREAM-LOCATION.
When unspecified UPSTREAM-LOCATION is the place \\[vc-push] would push
to. When called interactively with a prefix argument, prompt for
@ -4180,6 +4184,10 @@ can be a remote branch name."
(vc--with-backend-in-rootdir "VC root-log"
(vc-incoming-outgoing-internal backend upstream-location
"*vc-outgoing*" 'log-outgoing)))
;; We plan to reuse the name `vc-log-outgoing' for the fileset-specific
;; command in Emacs 32.1. --spwhitton
(define-obsolete-function-alias 'vc-log-outgoing #'vc-root-log-outgoing
"31.1")
(defun vc-default-log-outgoing (backend buffer upstream-location)
(let ((incoming (vc--incoming-revision backend upstream-location))

View file

@ -984,7 +984,7 @@ contains key `:tags' use its value as tests tags."
(should
(package-vc-tests-package-vc-async-wait
5 1 '("log" "--decorate")
(package-vc-log-incoming (package-vc-tests-package-desc pkg t))
(package-vc-root-log-incoming (package-vc-tests-package-desc pkg t))
t))
(let ((incoming-buffer (get-buffer "*vc-incoming*"))
(pattern (rx (literal