Re: [PATCH v2 3/3] Add option to transpose parents of merge commit

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, Nov 27, 2012 at 06:18:00PM -0800, Junio C Hamano wrote:
> Kacper Kornet <draenog@xxxxxxxxxxxxx> writes:

> > +--transpose-parents::
> > +	Transpose the parents in the final commit. The change is made
> > +	just before the commit so the meaning of 'our' and 'their'
> > +	concepts remains the same (i.e. 'our' means current branch before
> > +	the merge).
> > +

> How does this interact with Octopus merges?

It moves the original first parent to the last position. And nothing
more. I have forgotten to mention it in the documentation.

> > diff --git a/builtin/commit.c b/builtin/commit.c
> > index ee0e884..ab2b844 100644
> > --- a/builtin/commit.c
> > +++ b/builtin/commit.c
> > @@ -1477,6 +1477,7 @@ int cmd_commit(int argc, const char **argv, const char *prefix)
> >  	} else if (whence == FROM_MERGE) {
> >  		struct strbuf m = STRBUF_INIT;
> >  		FILE *fp;
> > +		int reversed_order=0;

> Style. s/=/ = /;

> > +	OPT_BOOLEAN(0, "transpose-parents", &reversed_order, N_("reverse order of parents")

> It smells more like "--reverse-parents" (if you deal only with
> two-head merges), no?

I have changes to --transpose-parents because of the octopus merges.
Although it is not a mathematical transposition in this case, but a cycle
permutation. 

-- 
  Kacper
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]