Short Version:

I wrote an awesome tool that replays Dojo's svn commits into a git repo
including branches and tags.

https://github.com/dojo-toolkit-mirror/dojo

Long Version:

For about a year, I've been using git for all my projects and manually
shoving Dojo into my repos. I got tired of that and about a month ago
started writing a Python script that will replay all Dojo commits into a
git repo that can be properly submoduled.

I have problems with the official Dojo mirror on GitHub. For starters,
it mirrors Dojo's trunk, which is not stable. It wasn't until last week
that Kris tagged some of the revs. Second, each project (dojo, dijit,
dojox, util, demos) repo in the official mirror are in their own
separate git repo. That's most likely because of the way git-svn works
and the way Dojo's svn repo is structured. When we bundle Dojo
releases, each of those projects are tied together and I think the repo
should reflect the same structure.

My tool will properly create branches and tags, though the tags are
somewhat pointless. It combines dojo, dijit, dojox, util, and demos
into a single repo.

I started at rev 15378, which is the commit used to cut Dojo 1.2. Why
1.2? Because it was the first release to include demos and is old
enough that if I can replay all commits from 1.2 to today, it should
handle all future Dojo 1.X commits. I'm hoping with Dojo 2.0 and the
AMD format that my tool becomes extinct.

The Python script works, but it's not perfect and the code is absolutely
crap, so if you love Python, brace yourself if you look at the code.
The only thing that bugs me is I didn't handle committers perfectly. It
shows that the committer as my server user, not the real committer.
Author works as expected though. Also, I tried my best to deal with
empty directories by adding a .gitignore file since git doesn't version
directories, but I think there are a couple scenarios where an empty
directory sneaks by.

I will be setting up a cron job on my server that will automatically
replay new commits. Inside the mirror's repo is a .svnrev file that is
used to track the rev. That file gets updated for each rev that is
replayed. This mirror is read only, except the replay commits.

The tool source can be found here:
https://github.com/dojo-toolkit-mirror/dojo-svn-2-git-tool

Fun facts... it took over 54 hours to siphon the 10,275 commits from svn
and create the git repo. The resulting git repo is 723MB in size.

I'm still testing to make sure this mirror is correct, but I figured
this might interest some other people too. Feedback is welcome!

-Chris

Search Discussions

Discussion Posts

Follow ups

Related Discussions

Discussion Navigation
viewthread | post
posts ‹ prev | 1 of 4 | next ›
Discussion Overview
groupdojo-contributors @
categoriesdojo
postedJun 28, '11 at 7:23p
activeJun 29, '11 at 7:49a
posts4
users3
websitedojotoolkit.org

People

Translate

site design / logo © 2022 Grokbase