[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Git conflicts
From: |
Johannes Schindelin |
Subject: |
Re: Git conflicts |
Date: |
Fri, 20 Jun 2008 18:27:25 +0100 (BST) |
User-agent: |
Alpine 1.00 (DEB 882 2007-12-20) |
Hi,
On Fri, 20 Jun 2008, Rune Zedeler wrote:
> Valentin Villenave skrev:
> > Yes, AFAICR I did it all by the book. Mainline is the branch you want
> > to come back to, I think.
>
> Ok, in that case I see no point in reverting and trying again.
> The result should be the same.
>
> Hmm, perhaps the best thing is to branch off a new branch (dev/rune2)
> just before the merge, and then cherry-pick the commits I did after the
> revert...?
This would be a rebase.
Basically, you have to find out what the relationship is between the two
branches you are trying to merge.
You can do that witk "gitk <branch1> <branch2>" (graphically), or with
"git show-branch <branch1> <branch2>" (text-mode).
Of course, for this you need to fetch the tracking branch, instead of
pulling it.
Now, if there are only a couple of commits you want to transplant, say
HEAD~15..HEAD, onto another branch, say "remotes/dev/rune2", you can call
this command:
$ git rebase -i --onto remotes/dev/rune2 HEAD~15
It will show you the list of the commits to be applied, and the rebase
("transplant") will start after you save and exit the editor.
Note: this command implies that the last commit you want to transplant is
the HEAD commit.
Hth,
Dscho
- Git conflicts, Rune Zedeler, 2008/06/19
- Re: Git conflicts, Rune Zedeler, 2008/06/19
- Re: Git conflicts, Valentin Villenave, 2008/06/20
- Re: Git conflicts, Rune Zedeler, 2008/06/20
- Re: Git conflicts, Valentin Villenave, 2008/06/20
- Re: Git conflicts, Rune Zedeler, 2008/06/20
- Re: Git conflicts,
Johannes Schindelin <=
- Re: Git conflicts, Rune Zedeler, 2008/06/20
- Re: Git conflicts, Rune Zedeler, 2008/06/20
- Re: Git conflicts, Rune Zedeler, 2008/06/20
- Re: Git conflicts, John Mandereau, 2008/06/20
- Re: Git conflicts, Rune Zedeler, 2008/06/22
- Re: Git conflicts, Valentin Villenave, 2008/06/22
Re: Git conflicts, Rune Zedeler, 2008/06/21
Re: Git conflicts, Johannes Schindelin, 2008/06/21