git@vger.kernel.org mailing list mirror (one of many)
 help / color / mirror / code / Atom feed
From: Junio C Hamano <gitster@pobox.com>
To: Taylor Blau <ttaylorr@github.com>
Cc: ZheNing Hu via GitGitGadget <gitgitgadget@gmail.com>,
	git@vger.kernel.org,
	Johannes Schindelin <Johannes.Schindelin@gmx.de>,
	Denton Liu <liu.denton@gmail.com>, Taylor Blau <me@ttaylorr.com>,
	ZheNing Hu <adlternative@gmail.com>
Subject: Re: [PATCH] [GSOC][RFC] format-patch: pass --right-only to range-diff
Date: Fri, 12 Mar 2021 14:09:33 -0800	[thread overview]
Message-ID: <xmqqv99w58iq.fsf@gitster.g> (raw)
In-Reply-To: <xmqq1rck6nr8.fsf@gitster.g> (Junio C. Hamano's message of "Fri, 12 Mar 2021 13:55:07 -0800")

Junio C Hamano <gitster@pobox.com> writes:

> Taylor Blau <ttaylorr@github.com> writes:
>
>> Note that I think (and Johannes--cc'd--could confirm) that what you want
>> is '--left-only' to discard rebased changes from the upstream branch:
>
> Does that mean range-diff got --left-only and --right-only
> backwards?  IOW, doesn't
>
> $ git log --left-only A...B
>
> show what is shown in "git log B..A", and if so, shouldn't
>
> $ git range-diff --left-only A...B
>
> which is a synonym for
>
> $ git range-diff B..A A..B
>
> also give commits in the B..A range?
>
> Puzzled....

Ah, it was only that "range-diff --help" uses confusing
double-negative phrasing.  I.e.

    --left-only::
            Suppress commits that are missing from the first specified range
            (or the "left range" when using the `<rev1>...<rev2>` format).

If you "suppress those that are missing from X", you are effectively
including only those that appear in X, so two conclusions I draw are

 - "range-diff" does not get "--left/right-only" backwards;

 - its documentation should be improved.

Perhaps

    --left-only::
	Include only commits that are in the first range (or the
	"left range" when using the `<rev1>...<rev2>` format).

wouldn't have made me puzzled.

Thanks.

  reply	other threads:[~2021-03-12 22:10 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-03-07  6:57 [PATCH] [GSOC][RFC] format-patch: pass --right-only to range-diff ZheNing Hu via GitGitGadget
2021-03-08 20:18 ` Taylor Blau
2021-03-09  7:28   ` ZheNing Hu
2021-03-12 21:55   ` Junio C Hamano
2021-03-12 22:09     ` Junio C Hamano [this message]
2021-03-09  8:33 ` [PATCH v2] [GSOC][RFC] format-patch: pass --left-only " ZheNing Hu via GitGitGadget
2021-03-09  9:00   ` Eric Sunshine
2021-03-09  9:35     ` ZheNing Hu
2021-03-09 10:28   ` [PATCH v3] " ZheNing Hu via GitGitGadget
2021-03-12 22:50     ` Junio C Hamano
2021-03-13  4:01       ` ZheNing Hu
2021-03-13 23:23         ` Junio C Hamano
2021-03-14  2:16           ` ZheNing Hu
2021-03-14  2:37             ` ZheNing Hu
2021-03-14  2:41               ` ZheNing Hu
2021-03-14  8:10     ` [PATCH v4] [GSOC] " ZheNing Hu via GitGitGadget

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

  List information: http://vger.kernel.org/majordomo-info.html

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=xmqqv99w58iq.fsf@gitster.g \
    --to=gitster@pobox.com \
    --cc=Johannes.Schindelin@gmx.de \
    --cc=adlternative@gmail.com \
    --cc=git@vger.kernel.org \
    --cc=gitgitgadget@gmail.com \
    --cc=liu.denton@gmail.com \
    --cc=me@ttaylorr.com \
    --cc=ttaylorr@github.com \
    /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.
Code repositories for project(s) associated with this public inbox

	https://80x24.org/mirrors/git.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).