From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Juri Linkov Newsgroups: gmane.emacs.bugs Subject: bug#51964: 29.0.50; Wishlist: It'd be nice with a pull+push command in vc-dir Date: Sat, 24 Sep 2022 20:36:37 +0300 Organization: LINKOV.NET Message-ID: <86h70w8y12.fsf@mail.linkov.net> References: <87wnl4wryu.fsf@gnus.org> <87pmfkykqw.fsf@gnus.org> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="21339"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (x86_64-pc-linux-gnu) Cc: 51964@debbugs.gnu.org To: Lars Ingebrigtsen Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Sat Sep 24 20:09:39 2022 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1oc9as-0005Mb-NI for geb-bug-gnu-emacs@m.gmane-mx.org; Sat, 24 Sep 2022 20:09:38 +0200 Original-Received: from localhost ([::1]:39962 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1oc9ar-0000BH-31 for geb-bug-gnu-emacs@m.gmane-mx.org; Sat, 24 Sep 2022 14:09:37 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:32830) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oc9aI-00009w-OZ for bug-gnu-emacs@gnu.org; Sat, 24 Sep 2022 14:09:03 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:46171) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1oc9aI-0000JF-Gl for bug-gnu-emacs@gnu.org; Sat, 24 Sep 2022 14:09:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1oc9aI-00026r-5v for bug-gnu-emacs@gnu.org; Sat, 24 Sep 2022 14:09:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Juri Linkov Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sat, 24 Sep 2022 18:09:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 51964 X-GNU-PR-Package: emacs Original-Received: via spool by 51964-submit@debbugs.gnu.org id=B51964.16640429038064 (code B ref 51964); Sat, 24 Sep 2022 18:09:02 +0000 Original-Received: (at 51964) by debbugs.gnu.org; 24 Sep 2022 18:08:23 +0000 Original-Received: from localhost ([127.0.0.1]:45249 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oc9Zf-000260-Hg for submit@debbugs.gnu.org; Sat, 24 Sep 2022 14:08:23 -0400 Original-Received: from relay12.mail.gandi.net ([217.70.178.232]:37909) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oc9Za-00025i-J5 for 51964@debbugs.gnu.org; Sat, 24 Sep 2022 14:08:21 -0400 Original-Received: (Authenticated sender: juri@linkov.net) by mail.gandi.net (Postfix) with ESMTPSA id 7C7E3200003; Sat, 24 Sep 2022 18:08:09 +0000 (UTC) In-Reply-To: <87pmfkykqw.fsf@gnus.org> (Lars Ingebrigtsen's message of "Sat, 24 Sep 2022 15:17:43 +0200") X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.io gmane.emacs.bugs:243553 Archived-At: >> `+' and `P' in vc-dir-mode are nice, but it means that I have to wait >> until `+' is done first. So what I want is a command that does the >> pull, and if there's no conflicts, then do the push. >> >> It seems like this shouldn't be too difficult -- vc-exec-after should be >> able to do this somehow. > > I've now done this in Emacs 29. I wonder why this couldn't be implemented by using the existing backend functions 'pull' and 'push'? Then the only thing required for a backend to support 'vc-pull-and-push' is just to return a process from the backend function 'pull'. IOW, I don't see a problem of moving the logic of vc-git-pull-and-push to vc-pull-and-push.