From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Dmitry Gutov Newsgroups: gmane.emacs.bugs Subject: bug#62940: 29.0.60; vc: no easy way to get diff of all outgoing changes Date: Fri, 11 Oct 2024 23:28:56 +0300 Message-ID: <59c272ef-9909-4e0a-b3d7-b42fc14e54cc@gutov.dev> References: <640746f7-fa1c-dfb9-aaab-f9d8effdf64f@gutov.dev> Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="25821"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Mozilla Thunderbird Cc: 62940@debbugs.gnu.org, Filipp Gunbin To: Spencer Baugh Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Fri Oct 11 22:30:23 2024 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 1szMHA-0006JM-NP for geb-bug-gnu-emacs@m.gmane-mx.org; Fri, 11 Oct 2024 22:30:17 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1szMGw-0007xE-5L; Fri, 11 Oct 2024 16:30:02 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1szMGs-0007wf-C8 for bug-gnu-emacs@gnu.org; Fri, 11 Oct 2024 16:29:58 -0400 Original-Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1szMGj-0000Y2-FI for bug-gnu-emacs@gnu.org; Fri, 11 Oct 2024 16:29:57 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=debbugs.gnu.org; s=debbugs-gnu-org; h=In-Reply-To:From:References:MIME-Version:Date:To:Subject; bh=YD1recTnlkDS8FqYuSZNp9A6J7He7nRtieCfv41ddjk=; b=otZVnkQWSt+wbaq+kBJnGXmJSji8FsOf5HaR0BbrybrVWhiMSGi3beKyRr/V33CxEq+VqcU+k8mmLntbUPFQKZSF7nBa7oXJIt/b8g89mxXyOpwtRf7ZLCxTeF165CQ9KNBtyaLF5YcZIY++PnoWT5u5eH8d4iaZEe5DD6bMBuq5C/4PZXXk6ODAUOGbGADvekGoZKoiDjHTS4ocdjo/shMeiXWRu7VhMp2sm827eG7IPIvoUsAXQQEHCyz6LQAF+eISEHTcRHJV8wPmO/5p9NlzvnZwRTPkjtl3ZzqbtpfmfevWqfTghIfHcZh/VO2C9jTXQGUqgrSKV3aXgZafpw==; Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1szMGw-0008JP-Iy for bug-gnu-emacs@gnu.org; Fri, 11 Oct 2024 16:30:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Dmitry Gutov Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Fri, 11 Oct 2024 20:30:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 62940 X-GNU-PR-Package: emacs Original-Received: via spool by 62940-submit@debbugs.gnu.org id=B62940.172867856231870 (code B ref 62940); Fri, 11 Oct 2024 20:30:02 +0000 Original-Received: (at 62940) by debbugs.gnu.org; 11 Oct 2024 20:29:22 +0000 Original-Received: from localhost ([127.0.0.1]:35433 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1szMGI-0008Hx-8a for submit@debbugs.gnu.org; Fri, 11 Oct 2024 16:29:22 -0400 Original-Received: from fout-a4-smtp.messagingengine.com ([103.168.172.147]:45527) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1szMGF-0008Hh-D1 for 62940@debbugs.gnu.org; Fri, 11 Oct 2024 16:29:21 -0400 Original-Received: from phl-compute-06.internal (phl-compute-06.phl.internal [10.202.2.46]) by mailfout.phl.internal (Postfix) with ESMTP id 064CD1380205; Fri, 11 Oct 2024 16:29:01 -0400 (EDT) Original-Received: from phl-mailfrontend-01 ([10.202.2.162]) by phl-compute-06.internal (MEProxy); Fri, 11 Oct 2024 16:29:01 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gutov.dev; h=cc :cc:content-transfer-encoding:content-type:content-type:date :date:from:from:in-reply-to:in-reply-to:message-id:mime-version :references:reply-to:subject:subject:to:to; s=fm1; t=1728678541; x=1728764941; bh=YD1recTnlkDS8FqYuSZNp9A6J7He7nRtieCfv41ddjk=; b= EsHIr8KwSQOLNNp0wUbQlGwyBcbrypif1BesKoXYB30+1/HGvu155yBl95LjXGvC 843F+hEXx7l1UcNTK+zuYBgfnE0Cgx+5qSKnc6Kqd1G9zF3odbjMt4J9gDv26tZE mS42lyOJ5jia203Zy4QNjfcyF+rVKdAm/OyJ1tXSi8plXRCnPIBXlZ+Ek2UG+m7/ UswcIacszr+Aau+NNY0ICxHFvwAYPSs13RI7MnA7mKcxUWC63Otjaw5JdZXoO3Uv T7D3hrW6MMwW4UiHvTi9YVqsEN8gTd53votWcLpxmWGi4cvoK6cCLeyUaVYyRfrg 4j6ArKRzxxTz+M+FihNvSw== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:cc:content-transfer-encoding :content-type:content-type:date:date:feedback-id:feedback-id :from:from:in-reply-to:in-reply-to:message-id:mime-version :references:reply-to:subject:subject:to:to:x-me-proxy:x-me-proxy :x-me-sender:x-me-sender:x-sasl-enc; s=fm2; t=1728678541; x= 1728764941; bh=YD1recTnlkDS8FqYuSZNp9A6J7He7nRtieCfv41ddjk=; b=F UaRXKvoddzhrVtShAaq+A0SyyXSw977GAFEjh9mzjonQjv4t/Gi2BROXlZ4cG32W GUwbmlnaBci2EimY7Lenv2I9UpQHK3TXYmkosM6asLvuBpVbC4Re5RbgUsKilvA/ 77Ur/+gzJH/yIP4D30/NVsMPru+XxKIHdAWC3cDTTkkM2+tWqF/P4pRr4ejrET8X OLeGYp65CQGIuT1n8kffD/k9C++cB7jBOGuiGP8aHQ7FRr6M66rh9KbKPGDo7emT S/IWRRDarC1rx7gLWDdKIhXzytgHrYwcN+Ux2eh1WdSQu95011jt1u+9Pz/xKnt6 xfxNdtimLpoKPYN/XmZnw== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeeftddrvdefkedgudeglecutefuodetggdotefrod ftvfcurfhrohhfihhlvgemucfhrghsthforghilhdpggftfghnshhusghstghrihgsvgdp uffrtefokffrpgfnqfghnecuuegrihhlohhuthemuceftddtnecusecvtfgvtghiphhivg hnthhsucdlqddutddtmdenucfjughrpefkffggfgfuvfevfhfhjggtgfesthekredttddv jeenucfhrhhomhepffhmihhtrhihucfiuhhtohhvuceoughmihhtrhihsehguhhtohhvrd guvghvqeenucggtffrrghtthgvrhhnpeegleefteekgffhvdfhtdegveevveetteegteev geettdehhfdukeetheffueekkeenucevlhhushhtvghrufhiiigvpedtnecurfgrrhgrmh epmhgrihhlfhhrohhmpegumhhithhrhiesghhuthhovhdruggvvhdpnhgspghrtghpthht ohepfedpmhhouggvpehsmhhtphhouhhtpdhrtghpthhtohepshgsrghughhhsehjrghnvg hsthhrvggvthdrtghomhdprhgtphhtthhopeeivdelgedtseguvggssghughhsrdhgnhhu rdhorhhgpdhrtghpthhtohepfhhguhhnsghinhesfhgrshhtmhgrihhlrdhfmh X-ME-Proxy: Feedback-ID: i07de48aa:Fastmail Original-Received: by mail.messagingengine.com (Postfix) with ESMTPA; Fri, 11 Oct 2024 16:28:59 -0400 (EDT) Content-Language: en-US In-Reply-To: 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-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.bugs:293380 Archived-At: On 11/10/2024 18:10, Spencer Baugh wrote: > Or alternatively if we would prefer to err on the side of warning the > user that the upstream has diverged, I suppose it's the Hg > implementation that would need to change. That can result a simpler > mental model and documentation as well. What would be Hg's > corresponding > selector for "tip of upstream branch"? > > > I'm not sure, I don't think there's no way to specify that with an hg > revset.  Though like most hg users, I don't actually use branches, I use > bookmarks; there's a way to do it with bookmarks, I think. I'll investigate. Thanks. Or if it doesn't make sense for Hg (for example, if the remote tip will always be present locally too), that would also be good, then the current implementation is just right. > I think it's useful to think of these two options relative to vc- > outgoing and vc-incoming.  Comparing $1 against $2 is equivalent to > getting the diff from $3: > - working-tree merge-base = vc-outgoing > - merge-base remote-tip = vc-incoming > - working-tree remote-tip = vc-outgoing+vc-incoming > > The first two are more useful than the third, I think, since the third > mixes together two sorts of diffs, making it ambiguous which is which. Makes sense. I think #2 might be more conveniently accessed from vc-log-incoming (which is the only way to view the separate commits and messages). Anyway, it seems instead of vc-root-diff we can use vc-diff-mergebase, it has the same completion for revisions. With REV1=@{upstream} and REV2="", we'll get #1, with reverse - #2. The full key sequence: C-u C-x v M D @{upstream} RET C-j Note that vc-*-mergebase is only implemented for Git. But vc-hg-log-incoming is defined -- that seems to indicate that 'mergebase' would be useful to support for it too.