emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

emacs-29 e31a5623965: * lisp/vc/vc-bzr.el (vc-bzr--pushpull): Return buf


From: Juri Linkov
Subject: emacs-29 e31a5623965: * lisp/vc/vc-bzr.el (vc-bzr--pushpull): Return buffer's process.
Date: Tue, 24 Jan 2023 13:29:17 -0500 (EST)

branch: emacs-29
commit e31a56239654a74b60e51f20799c8b09522082e4
Author: Juri Linkov <juri@linkov.net>
Commit: Juri Linkov <juri@linkov.net>

    * lisp/vc/vc-bzr.el (vc-bzr--pushpull): Return buffer's process.
    
    * lisp/vc/vc-git.el (vc-git--pushpull): Add comment.
    
    * lisp/vc/vc.el (vc-pull-and-push): Expand docstring about
    prerequisites for backend to support this command (bug#60569).
---
 etc/NEWS          | 2 +-
 lisp/vc/vc-bzr.el | 4 +++-
 lisp/vc/vc-git.el | 1 +
 lisp/vc/vc.el     | 3 ++-
 4 files changed, 7 insertions(+), 3 deletions(-)

diff --git a/etc/NEWS b/etc/NEWS
index 5da9a069736..b034dab7e61 100644
--- a/etc/NEWS
+++ b/etc/NEWS
@@ -2080,7 +2080,7 @@ This is in addition to the old keybindings 'C-c C-n' and 
'C-c C-p'.
 ---
 *** New command 'vc-pull-and-push'.
 This commands first does a "pull" command, and if that is successful,
-does a "push" command afterwards.
+does a "push" command afterwards.  Currently supported in Git and Bzr.
 
 +++
 *** 'C-x v b' prefix key is used now for branch commands.
diff --git a/lisp/vc/vc-bzr.el b/lisp/vc/vc-bzr.el
index 6443f6d57aa..f66e37fffa4 100644
--- a/lisp/vc/vc-bzr.el
+++ b/lisp/vc/vc-bzr.el
@@ -381,7 +381,9 @@ If PROMPT is non-nil, prompt for the Bzr command to run."
           (setq-local compile-command
                       (concat vc-bzr-program " " command " "
                               (if args (mapconcat #'identity args " ") "")))))
-      (vc-set-async-update buf))))
+      (vc-set-async-update buf)
+      ;; Return the process for `vc-pull-and-push'
+      (get-buffer-process buf))))
 
 (defun vc-bzr-pull (prompt)
   "Pull changes into the current Bzr branch.
diff --git a/lisp/vc/vc-git.el b/lisp/vc/vc-git.el
index 04aa37d6400..7ae763d2ee4 100644
--- a/lisp/vc/vc-git.el
+++ b/lisp/vc/vc-git.el
@@ -1168,6 +1168,7 @@ If PROMPT is non-nil, prompt for the Git command to run."
                           (lambda (_name-of-mode) buffer)
                           nil))))
     (vc-set-async-update buffer)
+    ;; Return the process for `vc-pull-and-push'
     proc))
 
 (defun vc-git-pull (prompt)
diff --git a/lisp/vc/vc.el b/lisp/vc/vc.el
index d4a3280f1bd..a181765eac3 100644
--- a/lisp/vc/vc.el
+++ b/lisp/vc/vc.el
@@ -3064,7 +3064,8 @@ On a distributed version control system, this runs a 
\"pull\"
 operation on the current branch, prompting for the precise
 command if required.  Optional prefix ARG non-nil forces a prompt
 for the VCS command to run.  If this is successful, a \"push\"
-operation will then be done.
+operation will then be done.  This is supported only in backends
+where the pull operation returns a process.
 
 On a non-distributed version control system, this signals an error.
 It also signals an error in a Bazaar bound branch."



reply via email to

[Prev in Thread] Current Thread [Next in Thread]