Thread (1 message) 1 message, 1 author, 2018-02-05

Re: cherry-pick '-m' curiosity

From: Junio C Hamano <hidden>
Date: 2018-02-05 19:55:59

Sergey Organov [off-list ref] writes:
Isn't it always the case that "mainline" is the first parent, as that's
how "git merge" happens to work?
You may not be merging into the "mainline" in the first place.

Imagine forking two topics at the same commit on the mainline, and
merging these two topics of equal importance together into a single
bigger topic, before asking the mainline to pull the whole.

    $ git checkout mainline
    $ git tag fork-point
    $ git checkout -b frontend-topic fork-point
    $ work work work
    $ git checkout -b backend-topic fork-point
    $ work work work
    $ git checkout -b combined
    $ git merge frontend-topic
    $ git tag merged

The backend-topic may be recorded as the first-parent of the
resulting merge, but logically the two topics are of equal footing,
so merge^1..merge and merge^2..merge are both equally interesting.


Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help