From: "Kristoffer Haugsbakk" <kristofferhaugsbakk@fastmail.com>
To: "D. Ben Knoble" <ben.knoble@gmail.com>,
"Junio C Hamano" <gitster@pobox.com>
Cc: "Matt Hunter" <m@lfurio.us>,
"Harald Nordgren" <haraldnordgren@gmail.com>,
git@vger.kernel.org, GGG <gitgitgadget@gmail.com>
Subject: Re: [PATCH v3] range-diff: add --matched-only to skip one-sided commits
Date: Wed, 04 Nov 2026 12:25:57 +0100 [thread overview]
Message-ID: <62095245-8121-4698-b1aa-ff239286d9e9@app.fastmail.com> (raw)
In-Reply-To: <427F4BDB-B21B-468E-9C6A-4A7FE3F13688@gmail.com>
On Tue, Nov 3, 2026, at 02:10, Ben Knoble wrote:
>> Le 2 nov. 2026 à 19:16, Junio C Hamano <gitster@pobox.com> a écrit :
>>
>> "Matt Hunter" <m@lfurio.us> writes:
>>
>>> Wouldn't invoking as
>>>
>>> git range-diff origin/master
>>> pr-git-2401/HaraldNordgren/range-diff-matched-only-v3
>>> range-diff-matched-only
>>>
>>> address this case?
>>
>> Three-rev form where <base> and two evolutions <rev1> and <rev2> are
>> given, and <base>..<rev1> and <base>..<rev2> are compared?
>>
>> I thought Harald's case was to take the patches from the previous
>> round of the topic and rebase them on top of a different base (e.g.,
>> updated origin/master), so there is no suitable single <base> for
>> the three-rev form, but I may have misunderstood his example.
>
> I think origin..old-topic and origin..new-topic
> would both select only the “topic” commits as long as both
> bases are reachable from origin (which seems to be the
> described case, to me).
>
> I agree with Matt that better selection of inputs to range-diff
> makes this specific case better :)
I use the
base..old base..new
Form as well.[1] Then it indeed does not matter if you have rebased or
not, as far as unrelated commits are concerned. You won’t get unrelated
commits.
But I don’t rebase topics here since I was told to not do it unless it
is needed. And also because then I get to use the often more readable
`--interdiff` output as well.
† 1: The repetition seems a bit inevitable and annoying, but I use a
script for assembling all of the options to git-format-patch(1).
next prev parent reply other threads:[~2026-11-04 11:27 UTC|newest]
Thread overview: 23+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-09-11 16:41 [PATCH] range-diff: add --matched-only to skip one-sided commits Harald Nordgren via GitGitGadget
2026-09-11 17:19 ` Junio C Hamano
2026-09-11 18:48 ` Harald Nordgren
2026-09-11 18:52 ` Junio C Hamano
2026-09-11 19:01 ` Harald Nordgren
2026-09-11 19:05 ` Junio C Hamano
2026-09-11 20:55 ` [PATCH v2] " Harald Nordgren via GitGitGadget
2026-09-14 16:33 ` Junio C Hamano
2026-09-15 7:51 ` [PATCH v3] " Harald Nordgren via GitGitGadget
2026-11-02 9:21 ` Junio C Hamano
2026-11-02 10:05 ` Harald Nordgren
2026-11-02 16:47 ` Ben Knoble
2026-11-02 21:03 ` Harald Nordgren
2026-11-02 21:15 ` Harald Nordgren
2026-11-03 0:01 ` Matt Hunter
2026-11-03 0:16 ` Junio C Hamano
2026-11-03 1:10 ` Ben Knoble
2026-11-03 1:56 ` Matt Hunter
2026-11-03 2:26 ` Junio C Hamano
2026-11-04 11:25 ` Kristoffer Haugsbakk [this message]
2026-11-04 18:00 ` Ben Knoble
2026-11-04 18:08 ` Kristoffer Haugsbakk
2026-11-02 22:01 ` Junio C Hamano
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=62095245-8121-4698-b1aa-ff239286d9e9@app.fastmail.com \
--to=kristofferhaugsbakk@fastmail.com \
--cc=ben.knoble@gmail.com \
--cc=git@vger.kernel.org \
--cc=gitgitgadget@gmail.com \
--cc=gitster@pobox.com \
--cc=haraldnordgren@gmail.com \
--cc=m@lfurio.us \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox