In the past few months we've been discussing on the infrastructure-dev mailing list about various ways of extending or improving the version control functionality available to Apache projects. One of the main themes of the discussion has been making it easier to access Apache codebases using git or other distributed SCM tools.
The new svn.eu.apache.org mirror that was recently announced supports git-svn use when accessed as an authenticated user over https. Unfortunately that access is limited to Apache committers and git-svn can be notoriously slow when making initial clones of complex codebases in svn.
To work around these issues I set up a collection of git mirrors of selected Apache codebases on my server. You can find these unofficial mirrors at http://jukka.zitting.name/git/. The mirrors are automatically updated daily.
The mirrors work pretty much like normal git repositories in that you don't need git-svn or any other svn tools to work with them. The only significant difference to normal git repositories is that svn tags are mapped to branches named "tags/..." in the mirrors due to the different way git and svn handle tags. Also, settings like svn:ignore, svn:eol-style, etc. are not replicated in these git mirrors.
Let me know if you're interested in seeing other Apache codebases mirrored. I'm also interested in other feedback or ideas related to these git mirrors.
Someone created a clone of your repo at repo.or.cz:
ReplyDeletehttp://repo.or.cz/w/stdcxx.git
Which can be cloned by http (which works better through firewalls).
Good point about HTTP. I've enabled it also on my server.
ReplyDeleteThank you so much. I kept getting bitten by trying to clone things from svn.apache.org. This is enormously useful to me so I can keep track of what's going on in various projects we use.
ReplyDeleteHow cool is that?!? Could you add a git clone of the logging projects (log4j, log4cxx, etc.) too?
ReplyDeleteDone. You'll now find log4j, log4cxx, log4net, chainsaw, and commons-logging included.
ReplyDeleteThanks a lot for this!
ReplyDeleteHow exactly do you have git-svn configured to export the normally remote branches? Are you using a post-update script to update the remote refs to be local?
I use the following script to copy the remote git-svn branches to local branches:
ReplyDeletegit update-ref refs/heads/master refs/remotes/trunk
git for-each-ref refs/remotes | cut -d / -f 3- | grep -v -x trunk |
grep -v @ | while read ref
do
git update-ref "refs/heads/$ref" "refs/remotes/$ref"
done
git for-each-ref refs/heads | cut -d / -f 3- | grep -v -x master |
while read ref
do
git rev-parse "refs/remotes/$ref" > /dev/null 2>&1 ||
git update-ref -d "refs/heads/$ref" "refs/heads/$ref"
done
Would you be so kind as to add Xalan-Java (svn.eu.apache.org/repos/asf/xalan/java) ?
ReplyDeleteRegards and thanks in advance
One mirror of Xalan Java coming up... Have fun!
ReplyDeleteCould you add cxf?
ReplyDeleteSure, the CXF mirror is now being created.
ReplyDeleteThanks!
ReplyDeleteStrange...why does it show the last change was 5 months ago?
ReplyDeleteThe initial sync is still running. Once it's done you'll see also the latest commits.
ReplyDeleteCan we get pluto too?
ReplyDeleteCheers!
Pluto is now mirrored (and the CXF mirror is complete). Have fun!
ReplyDeleteWoah that was quick! Now I gotta go throw out my svn checkout and clone - cheers!
ReplyDeleteBtw - got any links to discussion about debate regarding Apache adopting Git?
The archives of the infrastructure-dev list where most of the recent git discussion at Apache has taken place can be browsed at http://dir.gmane.org/gmane.comp.apache.infrastructure.devel
ReplyDeleteCan you setup an 'email notification' option to the comments in your posts?
ReplyDelete> Can you setup an ‘email notification’ option to the comments in your posts?
ReplyDeleteI don't know how to do that (or if the feature is even available) on wordpress.com.
You can subscribe the feed at http://jukkaz.wordpress.com/2008/07/31/git-clones-of-apache-codebases/feed/ to keep up with comments on just this post.
Hi Jukka!
ReplyDeleteIt was nice meeting you at Apachecon last week. Any way you can add mahout to the git repo?
Thanks!
Thanks for the reminder! Apache Mahout is now mirrored.
ReplyDeleteSweet! Thanks again!
ReplyDeleteHi Jukka,
ReplyDeleteCan you add OpenJPA to the list please?
Also, do you have a link to anything about best practices for committers using git + Apache's svn repo?
Thanks!
The OpenJPA mirror is now coming up. The initial sync probably takes some while (hours or even days). I'll ping you when it's ready.
ReplyDeleteI've been planning to write up a summary of the git@Apache talk I gave a month ago at the BarCamp Apache, but I haven't yet gotten it done. :-( I'll try to do that in the next few days.
If you haven't already seen them, you should check out the archives of the infrastructure-dev@ list for some good discussion on the various things people have been doing with git.
Thank you very much!
ReplyDeleteSorry. Subscribing to comments...
ReplyDelete