I had a chat with the jorendorff today about what I need to do to get my Mercurial (aka hg) project rolling. He outlined the steps we should look to take…
- We have to make sure you understand hg
- We have to decide on some very small thing that you can get running very soon
- We should talk it over and make sure it’s clear how to do it
- We should plan to meet up later and brainstorm some, once you’ve had a chance to play around with hg
I can add another point to this. I need to decide what exactly I will be doing for my 0.1 version release. Right now I don’t have a clue. But first things first, I need to install and play around with hg. Here goes…
I will be installing on Vista (yeah, I know what you’re thinking but seriously, it works fine) so I need to find a windows installation. The installing Mercurial guide recommends just installing MozillaBuild since hg comes packaged with it. But I rather not do that at the moment because I don’t need the rest of the tools from MozillaBuild. Well, I was in luck since there are binary packages for Windows here and even Mac. So I downloaded the binary and went through the installation.
Now to check if hg installed properly just head to the dir where you installed it (using cmd) and run hg.exe. Then type hg version to get the version info. You should get something like this…
Now, I needed to make some changes to a config file. All the guides I read were telling me to make changes to a hgrc file but I couldn’t really find any config file with that name. It turns out you need to make changes to Mercurial.ini file for windows and the hgrc file is for UNIX systems. Here you need to tell hg what merge program to use. I decided to go with TortoiseMerge since I am already familiar with TortoiseSVN.
Downloading Mozilla Source
Now to get to the real part. All the preliminary work leads up to the moment of truth! Downloading the Mozilla trunk source! Now to do this you need to use the hg clone command and pull from http://hg.mozilla.org/mozilla-central/
One thing that hg desperately needs is a way to know your download progress. If you haven’t ever downloaded the Mozilla source then let me just tell you that it is HUMONGOUS! I’m not kidding. It took forever to download it. Ah, command line tools, you win some and you loose some.
What’s next after downloading the source? Well you can do many things i.e. pull a file and make changes to it then push it back in and much much more. Since I will be working with everything related to history I decided to try out the hg log feature. This command, by default prints each change recorded to the project. Each of these recorded events are known as changesets because they can contain records of changes to several files.
I will continue to play around with hg and hopefully make progress. Meanwhile jorendorff has a post on his blog about hgweb in which he’s calling for ideas to improve it (this will be my job) so go over there and contribute!