Hello, I've written a simple tool for interoperating between git and svn. I wrote this so I could use git to work on projects where other developers use Subversion. I really hate using svn, but some projects I work on require it, and svk isn't nearly as fast nor simple as git. git-svn does not replace git-svnimport, git-svnimport handles branches and tags automatically, but is too inflexible about repository layouts to be useful for a good number of projects I follow, and of course git-svnimport can't commit to Subversion repositories :) git-svn only cares about a single branch/trunk in SVN[1], but you can use as many branches in git as you want. This makes it much easier to use and allows it to handle just about any repository layout, not just those recommended in the SVN book/developers. Although importing changesets from SVN is mostly a linear affair, committing to SVN is the opposite. You may commit git tree objects in any order you want. It simply clobbers the existing svn tree as 'git-checkout -f' would, but tags file renames/copies carefully so users on the SVN side can see them. You can even do some wacky things with patch reordering. Basic day-to-day usage is pretty simple, and is designed to work with and also work like normal git commands: # Initialize a tree (like git init-db):: git-svn init http://svn.foo.org/project/trunk # Fetch remote revisions:: git-svn fetch # Create your own branch to hack on:: git checkout -b my-branch git-svn-HEAD # Commit only the git commits you want to SVN:: git-svn commit <tree-ish> [<tree-ish_2> ...] # Commit all the git commits from my-branch that don't exist in SVN:: git rev-list --pretty=oneline git-svn-HEAD..my-branch | git-svn commit # Something is committed to SVN, pull the latest into your branch:: git-svn fetch && git pull . git-svn-HEAD @ Junio: Is there room for this in the git distribution alongside git-svnimport? Thanks for reading, [1] - there are some a hacks that lets you handle branches and tags, but it's not automated in any way, requires a bit of imagination to use to its full potential, and is very much a hack. See the man page :) -- Eric Wong - To unsubscribe from this list: send the line "unsubscribe git" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
This archive was generated by hypermail 2.1.8 : 2006-02-16 18:39:31 EST