Bluish Coder

Programming Languages, Martials Arts and Computers. The Weblog of Chris Double.


Changes to git mirror of Firefox repository

I've made changes to the way I manage the git repository holding the import of the Firefox source. Since the bulk of the HTML 5 <video> implementation is now in the main Firefox source I no longer maintain the video branch. I'll be removing that and the Firefox mirror soon.

The main Mozilla repositories have been split into two now. They are mozilla-central, which holds the current trunk code and represents Firefox 3.2 (or whatever the next version will be called), and mozilla-1.9.1, which is what will be Firefox 3.1. The details of that split are described in this post.

I now import these mercurial repositories directly into git using git's fast import tool. This gives me complete history and makes things like bisect and blame a bit easier to work with. The history of mozilla-1.9.1 being based on mozilla-central is also retained, as best as I could manage. These imported repositories can be browsed at They can be retrieved via git:

git clone git://
git clone git://

The way I work with these mirrors is to create a git repository that has these added as remotes. This way I can switch between the two easily, cherry pick patches between them, and do logs and diffs between them. This is how I set that up:

$ mkdir firefox
$ cd firefox
$ git init
$ git remote add mozilla-central git://
$ git remote add mozilla-1.9.1 git://
$ git fetch mozilla-central
$ git fetch mozilla-1.9.1

When working on a bug I create a branch for that bug, based on mozilla-central/master:

$ git checkout -b bug123456 mozilla-central/master
...make changes...
$ git commit -a -m "my changes"
$ git diff -U8 mozilla-central/master >bug123456.patch
...attach bug123456.patch to bugzilla for review...

Once reviewed the patch is then applied to mercurial and pushed. If I want to apply the same patch to test on the mozilla-1.9.1 branch I just use 'git cherry-pick'. To make things like 'git status' a bit less clutted I have the following .gitignore:

$ cat .gitignore


This site is accessable over tor as hidden service 6vp5u25g4izec5c37wv52skvecikld6kysvsivnl6sdg6q7wy25lixad.onion, or Freenet using key: