Re: [RFC PATCH] cherry-pick: set default `--mainline` parent to 1
- From
Sergey Organov <sorganov@gmail.com>
- Date
- Mar 20, 2019, 12:01 UTC
- Message-ID
- <871s31vjo7.fsf@javad.com>
- In-Reply-To
- <xmqq1s32w3vu.fsf@gitster-ct.c.googlers.com>
Junio C Hamano <gitster@pobox.com> writes:
[...]
Show 8 quoted lines
> But I do have a very strong opinion against adding yet another > option that takes an optional argument. If we want to allow > cherry-picking a merge commit just as easy as cherrry-picking a > single-parent commit, "git cherry-pick -m merge" (assuming 'merge' > is the tip of a branch that is a merge commit) that still requires > the user to say "-m" is not a good improvement. We should just > accept "git cherry-pick merge" without any "-m" if we want to move > in this direction, I would think.
Let's just make '-m 1' the default option indeed. No need for further complexities.
Exactly according to what Junio has already said before. Here:
https://public-inbox.org/git/xmqqsh5gt9sm.fsf@gitster-ct.c.googlers.com
Junio wrote:
Show 6 quoted lines
> Now, it appears, at least to me, that the world pretty much accepted > that the first-parent worldview is often very convenient and worth > supporting by the tool, so the next logical step might be to set > opts->mainline to 1 by default (and allow an explicit "-m $n" from > the command line to override it). But that should happen after this > patch lands---it is logically a separate step, I would think.
... and as that patch already landed...
-- Sergey