- Backup your project:
- Transfer one module to a svn repo:
cvs2svn -s MODULE ../PLACE_YOU_DID_RSYNC/MODULE
- Install the svn2git:
git clone git://github.com/jcoglan/svn2git.git
rake gem
sudo gem install pkg/svn2git-1.0.0.gem
# On ubuntu you run it with /var/lib/gems/1.8/bin/svn2git file:///... - For each module, you will create an empty directory and inside that directory run:
/var/lib/gems/1.8/bin/svn2git file:///PATH_TO_MODULE
- Well, this gives you a bunch of modules, with their branches, if you had them. So, from here, your hell begins... Myself, I had 3 modules, that I checkout in branches. I did it in empty branches for each module:
git symbolic-ref HEAD refs/heads/MODULE_NAME
#removed everything from the old branch switch...
rm .git/index
git clean -fdx
git pull PATH_TO_GIT_SVN_MODULE
git push --all - You can also move some remote branches, or move:
git push origin origin/OLD:refs/heads/NEW
# delete the old branch
git push origin :OLD - This should give you enough flexibility and people can still use those branches. Idealy, you should have super-project and sub-projects. But git is not that great on that yet... and the tools are also failing on this topic.
- You can see the results from here: http://jlibdc1394.git.sourceforge.net/git/gitweb.cgi?p=jlibdc1394
rsync -av rsync://jlibdc1394.cvs.sourceforge.net/cvsroot/jlibdc1394/* .
No comments:
Post a Comment