Re: [PATCH 2/2] diff-merges: introduce '-d' option
- From
Junio C Hamano <gitster@pobox.com>
- Date
- Sep 26, 2023, 17:08 UTC
- Message-ID
- <xmqqa5t8ooaj.fsf@gitster.g>
- In-Reply-To
- <87bkdpl2yx.fsf@osv.gnss.ru>
Sergey Organov <sorganov@gmail.com> writes:
> No need to ask for a new option, as the behavior you describe is already > there, and is spelled "git log --diff-merges=first-parent" > (--diff-merges=1 for short).
Ah, that changes things.
Making "--diff-merges=<how>" only about the presentation of merge commits, requiring a separate "-p" for single-parent commits [*], does make the life for those in the "merges are the only interesting things" camp a lot easier, exactly because the lack of "-p" can be used to say "I am not interested in chanages by single-parent commits".
Side note: I personally think it is a design mistake of --diff-merges=<how> (e.g., --cc and --diff-merges=cc do not behave the same way) but that is a different story, and it is way too late now anyway to "fix" or change.
So "-d" that stands for "--diff-merges=first-parent -p" makes the more useful (to those who think "merges are the only interesting things", which I do not belong to) "--diff-merges=first-parent" (without "-p") less useful. And the combination is not useful for those of us who find individual patches plus tweaks by merges (either --cc or --remerge-diff) are the way to look at the history.
I still do not think that we want to give a short-and-sweet single letter option for such a combination.
Thanks for clarification.