Search code examples
gitsvngit-svnsvn2git

Including branches that were created after conversion


I'm in the process of converting a large repository from SVN to Git. I've used SVN2Git to handle the conversion. However, it takes a very long time. So, I've been using the svn2git --rebase command to bring in changes while we test, prepare our CI and build infrastructure, etc.

However, I'm unsure how I'm supposed to be handling changes to branches, or branches that get added. For example, someone created a branch today, and I need to bring it in. I ran my svn2git --rebase (against [master]), and it updates master as expected but the new branch didn't get converted over.

This makes me question whether or not it's updating the existing branches. So, what does svn2git do during --rebase, exactly, but more importantly, how can I make sure my branches are getting updated and any new ones are also being converted?

I'll even settle on how to manually convert or update git branches from svn, as there aren't many, but they are important.


Solution

  • In my case, I just ended up calling svn2git with the same parameters as I had originally used, except I used -revision to skip ahead to the commit of the branch I'm interested in.

    I'm not sure if that's the correct way, but it worked for me.