[LLVMdev] git-svn dcommit Question

Tobias Grosser tobias at grosser.es
Tue Jul 5 14:20:18 PDT 2011

On 07/05/2011 03:48 PM, David A. Greene wrote:
> Rafael Ávila de Espíndola<rafael.espindola at gmail.com>  writes:
>> On 07/05/2011 03:27 PM, David Greene wrote:
>>> My git-svn fu is not very strong.
>>> In the course of preparing a set of AVX patches, I've committed several
>>> changes to my local LLVM git clone.  I don't want to send all of those
>>> changes upstream right away.  What's the best way to send just the first
>>> of those changes us using git-svn?  dcommit appears to send all pending
>>> changes.  Is there a way of branching/cherry-picking that will
>>> accomplish what I want?
>> Create a cmt branch from master and add just the patches you want to
>> commit to it.
> Ok, that's what I thought I should do.  I just needed to confirm that.
> So git-svn dcommit only commits things on the current branch.  Cool, I
> think I can make this work.
> Will git-cherrypick work or is the merging process going to confuse
> git-svn?

To use git-svn you should always have a history without any git merges. 
Just commit after commit after commit. I do not know what kind of 
history git-cherrypick produces.

I would do the cherrypicking like this:

git checkout -b toCommit
git rebase -i HEAD~30

 > Remove all the unneeded commits in the upcoming window

git svn -n dcommit // Check what would be committed
git svn dcommit // Commit


More information about the llvm-dev mailing list