From: Sean Whitton Date: Fri, 4 Jul 2025 10:38:38 +0000 (+0100) Subject: New history variable for VC remote locations X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=f5adb9b24afed53bf89a35501590fccc5da0fa65;p=emacs.git New history variable for VC remote locations * lisp/vc/vc.el (vc-remote-location-history): New variable. (vc--maybe-read-remote-location): Use it. (cherry picked from commit 625a9f9bce77e47bd71d7f74e8011c716e0645cc) --- diff --git a/lisp/vc/vc.el b/lisp/vc/vc.el index c13ad105fbf..7ae54e6894c 100644 --- a/lisp/vc/vc.el +++ b/lisp/vc/vc.el @@ -3289,9 +3289,13 @@ The command prompts for the branch whose change log to show." (list rootdir) branch t (when (> vc-log-show-limit 0) vc-log-show-limit)))) +(defvar vc-remote-location-history nil + "History for remote locations for VC incoming and outgoing commands.") + (defun vc--maybe-read-remote-location () (and current-prefix-arg - (list (read-string "Remote location/branch (empty for default): ")))) + (list (read-string "Remote location/branch (empty for default): " + 'vc-remote-location-history)))) (defun vc--incoming-revision (backend remote-location) (or (vc-call-backend backend 'incoming-revision remote-location)