git-svn users: please squash commits on branch merge

Soren Harward stharward at gmail.com
Sun Jul 5 02:26:22 CEST 2009


For those of you what are using git-svn, when you merge a branch back
into the main tree to get it ready for an SVN commit, could you please
squash your merge history so that you don't end up with a new SVN
commit for each git commit?  I really don't think it's necessary to
have the entire work history of your private branch put into the
public SVN; that's kind of the point of the private branch.  Just big
commit is a lot easier to review, and is kinder to SVN.

If you don't know what I'm talking about, here's what your workflow
probably looks like:

[finish work on mybranch]
git checkout master
git merge mybranch
git svn dcommit

Please do this instead:

[finish work on mybranch]
git checkout master
git merge --squash mybranch
[edit the commit message so that it's appropriate the whole commit]
git svn dcommit

--
Soren Harward
[who tips his hat to Ian who posted this tip on the Git development
page in the first place].


More information about the Amarok-devel mailing list