Git Vs Mercurial (Updated)

I have used Git at work and while working on linux kernel for more than one year now. Apart from this my work gives me an oppurutnity to work with the git’s close cousin Mercurial aka Hg.

My experiences with Git are good not at all bad i must admit. Initially the learning curve was huge for me, i must confess.But once i started getting used to the whole concept of Distributed SCMs it felt nice and easy and pretty logical to work in a distributed working mode.Though I insisted on using Git at work(..yes thats correct at work) for internal projects, i was faced with challenge of coming up with less muck ups and more smiling faces around. Sadly the reality bite count disappointed me.Most of the developers were spellbound on what git was doing and more importantly how?. Well others were really dumb to never able to understand Git. Looks like Git needs a minimum IQ level to understand its working principle and usage.Anyway whatever, once it was through atleast some of the developers were impressed with Git.I must also admit higher managment was skeptical and less of supportive…aah usual corporate stuff. I am enjoying using git every day.I am hooked to cheap branches, excellent merging capability, blazing fast speed and distributed nature. Some things which i felt were really commendable were the git-revert and hard resetting feature.Wow! i was able to undo a bad commit, which showed up after a lot of commits since faulty merge by the team. Branching is supercool and simple. Just a git-branch state-23-7-07 abe56ff12…. , and you have a pristine branch from the commit with id abe56ff12…. .Extremely handy. Seriously ,as Linus somewhere mentioned Git is more of a filesystem rather than a SCM tool.

Mercurial has been a pleasant surprise.Though, i had my share of problems using Hg after using Git for pretty everything i wrote at work and at home too.

Okay here is the updated entry, short answer Git is better than Mercurial, hands down. Only place when mercurial wins is ease of use for newcomers.But once you get over this happy feeling of easyness and start asking for more from mercurial, it falls down flat on its face. With all apologies to Matt Mackal and the wonderful team of Mercurial, I still find mercurial to be a little behind git. No doubt it is easy and fast. But git is more robust and rather mind boggling when it comes to saving a developers life.

I hope I am wrong here in my interpretations over mercurial but mercurial’s named branch support within one repository sucks big time. Perhaps I am doing it wrong because I come from git land(?). But it is a little clumsy to work with named branches in a single mercurial repository, unlike git where it is perfectly nice. hg revert disappointed me when working with mutiple named branches in same directory.

Well, still what i like about mercurial apart from ease of use and usually said stuff is, its hg export. It is nice and quite handy to generate a patch for my changesets. Hg is indeed a cool software which i like and use but still I think Hg can learn a thing of two from git and vice versa.

No comments yet

Leave a comment