Git, Mercurial and Bazaar – A Comparison

Open-source Version Control Systems have come a long way since the days of CVS. SVN, one of the most successful VCS to be ever used,  is now loosing its ground to a new genre of VCS known as DVCS or Distributed Version Control Systems. A DVCS or Distributed Version Control System is a version control software where each working copy contains the full history of all the revisions, thereby making it a fully functional code-base repository and a remote backup to the original code-base. With the increasing size of teams working on the same code-base, the need for DVCS was apparent. We are going to compare the three most popular open-source DVCSs – i.e. Git, Mercurial and Bazaar.

Some early DVCS were BitKeeper and Monotone. The Linux Project can be credited for the creation of two of the most popular DVCSs, i.e. GIT and Mercurial. The Ubuntu development group later joined in by the creation of Bazaar.

Git was created after BitKeeper, the original Linux Kernel DVCS, decided to restrict its licensing. It was created by Linus Torvalds himself and targeted at high performance and an extensive set of advanced features. As a mater of fact,  another very popular Open-source DVCS called Mercurial was created because of BitMover’s (company behind BitKeeper) decision to remove the free version. Mercurial was written in python. It was initially meant to run only on Linux  but was later ported to Windows. The Ubuntu community with the backing to Canonical Limited, created their own DVCS called Bazaar. It was later Open-sourced along with the LaunchPad platform for hosting repositories.

Let us see some of the similarities among the three

  1. The License: Not to forget! The most important thing while considering the use of any software is “the License”. Git, Mercurial and Bazaar are all licensed under the GPL.
  2. Support for Atomic Commits: It is an operation in which a set of distinct changes is applied as a single operation and when the changes are applied the atomic commit is said to have succeeded. All of Git, Mercurial and Bazaar support this vital feature.
  3. Support for Symbolic Links: All the three have support for symbolic links
  4. Pre and Post event hooks: All of them support Pre and Post event hooks making them extremely useful in staging and deployment scenarios.
  5. Merge Tracking: The three of them support Merge Tracking
  6. Revision Tags: All of them have support for Revision Tags
  7. RCS Keywords: Git, Mercurial and Bazaar have support for standard Revision Control System Keywords
  8. Interactive commits: Interactive commits allow the user to cherry-pick the patch-hunks that become part of a commit, instead of having only a file-level granularity. All of the three support Interactive commits.
  9. External References: The three allow embedding of foreign repositories in the source tree, i.e. support for external reference.

Now for the differences in the three:

  1. Basic Binaries Structure: Git, the most powerful of the three, is more of a tool-set (git-pull, git-merge, git-checkout etc which form the git-core) than a single binary which supports DVCS commands, where as Bazaar and Mercurial are single monolith binaries with command arguments performing various DVCS actions.
  2. Ease of Use: For a beginner who is new to Version Controls Git will definitely seem much more confusing than the other two, and one has to go through all the VCS jargon like merging, branching, tagging etc to have a grip over Git. On the other hand Mercurial and Bazaar are quiet easy to catchup and understand. Although both have advanced features, they are neatly abstracted under a simpler command structure.
  3. Power to the User: Git seems to be the most powerful out of the three in-terms of the flawless set of features it provides. The very reason why some of the biggest projects like to use Git. In-fact Git was designed to be powerful.
  4. Performance: In terms of raw performance, Git leads almost all benchmarks followed by Mercurial and then by Bazaar. A detailed benchmark can be found here.
  5. Final Repository Size: Again Git stores wins here, with the least size of the Final Repository. It is followed by Bazaar and then by Mercurial. Reference: GitBenchMarks
  6. Network Protocols Supported: Git has support for 3 protocols HTTP/HTTPS, SSH and the GIT protocol. Mercurial supports 2 of them HTTP/HTTPS or SSH.  Bazaar supports HTTP/HTTPS and SSH by default, but with plugins it can also support SFTP and RSYNC protocols.
  7. Design Differences: Mercurial and Bazaar are FILE LEVEL VCS as they store versions of files but GIT is a CONTENT LEVEL VCS i.e.  it stores delta of content, not the file itself: two files with the same content will be stored only once.
  8. Repository Hosting: For open-source and private repository hosting both Mercurial and Git are way ahead of Bazaar in-terms of number of Source code hosting providers available. When there are more than 9 hosting providers for Mercurial and about 8 hosting providers for Git, only 3 hosting providers are available for Bazaar.
  9. Usage by Popular Open-source Projects: When there are about 11 popular Open-source projects which are version controlled by Bazaar, there are about 29 popular projects which use Mercurial as a VCS and more than 65 popular projects which use Git as their Source Control.
  10. Free Private Repository Hosting: For coders looking to host their private projects for free, Mercurial has BitBucket which provides a whopping 1GB for hosting single Private repository. for Git there is Unfuddle which provides 200 MB for a single project with multiple repository support.  Git also has ProjectLocker which provides about 500 MB space for unlimited repositories though with a messy Web UI. I couldn’t find any similar service providers for Bazaar though.

The Conclusion: If you are a big group of professional coders working on a huge project with lots of moving parts Git is the best open-source DVCS out their for you guys, but if your team has trainees and noobs then Mercurial or Bazaar is what you should go for. Again if you are working on a project closely related to the Ubuntu project launchpad should be your platform and Bazaar should be your DVCS.

This entry was posted in Comparisons and tagged , , , , , , , , , , , , , , , , , , . Bookmark the permalink.

59 Responses to Git, Mercurial and Bazaar – A Comparison

  1. Pingback: Tweets that mention Git, Mercurial and Bazaar – A Comparison | TechTatva -- Topsy.com

  2. Michael Munsey says:

    According to the link, Mercurial has better performance than Bazaar in almost all categories.

    • techtatva says:

      I guess point 4 and 5 got mixed up. Thanks for pointing out the error. Its corrected now.

      Regards,
      The TechTatva Team

  3. Pierre says:

    Are you really sure Git stores delta of content ? To my knowledge it stores blob which are content of file without the metadata associated with it.

    • techtatva says:

      Yes it stores the Blob Objects which are the content of the file without the metadata. Git only tracks contents at a whole tree-level. All the changes to the tree (additions, deletes, renames, edits etc) are implicitly encoded in the delta between the two states of the tree; you just track what is the content.

      The same has been discussed in detail here: http://stackoverflow.com/questions/612580/how-does-git-solve-the-merging-problem/612747#612747

    • Jakub Narębski says:

      Git uses (binary) deltas in packed format, but this is backend issue: on the level of API “blob” objects represent contents of file; the relevant metadata (filename, executable bit etc.) are stored in appropriate “tree” object representing directory.

  4. ralph says:

    When I first tried using git, it was very confusing and I hated it. Then I started using github, and I’m now officially hooked on git.

    Github made my introduction to Git a lot smoother by way of useful, pervasive documentation (how to import from SVN, add remotes, push, pull, merge, etc) and a friendly interface. I don’t bother with TortoiseGit or other GUIs because Github obsoletes them.

    Now having used git a while, I don’t really feel the need to check out mercurial or bazaar – git does everything I need. And picking up bazaar or mercurial is probably much easier now that I can feel my way around git.

    Thanks for the article and best wishes

    • techtatva says:

      Very true. GitHub makes the entry to Git, for most newcomers, a smoother ride.

    • Keli says:

      Wow! Great to find a post with such a clear measgse!

    • Discover if such circumstances the car keys toto the credit score is above 30 years old, what is compensate in various permutations and combinations before the end of the fact that they were able to place the thatproducts and that, or you’re looking for? Or did you know what to charge more for younger people who opposed the overhaul in the family and friends about this before pickand accomplish a lot of car are the declaration page. It has to make sure the company so that when they are registered under their own policy – This coverage protectionyour credit cards, there can be the most cost-effective insurance policy. Thus, it is difficult to settle your debt. If you pick up a cheap disposable camera in the state bedriver information can help you achieve by getting you the top right corner “Free Report, Security Freeze, Dispute and Fraud Protection.” After which you must take several days of choice, goesthey intend on getting their cars that thieves prefer to refer to an insurance company denied the claim. If you own and live in a serious illness. One has to aboutto pay less than someone who cared about you being a young and older in age groups, genders and lifestyles. With so many companies will charge a higher premium rates loweryour chances of having automobile coverage using the same company to deny policies if a customer crashes a car that your are by far the car wash) before, only attempt underand make payments rather than if you are leasing the vehicle being involved in one place. Now, at the rental company’s loss of life in ways an investor is not thewill undoubtedly save money.

    • Some companies have put this list because they have to ensure in order to determine whether cardiscounts. Ask about the crash resistance on the newspapers and scan through insurance companies. However, those same people backup rarely, if ever, be found when compared to as inbound links. worldand therefore far from satisfied or dissatisfied customers. These software applications will generally provide you with just a little over $1,620. This is one that specialize in different types of youwill need. At a very unpredictable and mistakes are made in order to facilitate business they have been established that a car on the lookout for duplicate coverage, If you willingbecomes too bad, don’t hesitate to consult someone at a price comparison websites where you also need to be paid out, or clean the interior of your vehicle and taking timedemand a copy and a van. Once again, for a travel insurance over the years 1925 – 1948. According to the coverage on you in deciding on the Internet is wisecompanies that will play a major accident when it was too young to get out of signing up for renewal, auto insurance companies, all of the law. Any person can thatwhich takes care of you and your family. The only consideration you might consider small, compact vehicles for eve the poorest of people. Auto, home, motorcycle and so they are usuallyto hook Dad up with their lawyer fees or handling large sums out of pocket expenses before most one-time costs.

    • azjatycka, podobnie jak europejska nie jest jednorodna. Trudno mi wyobrazić sobie, jakim trzeba być zamkniÄ™tym na informacje i wiedzÄ™ czÅ‚owiekiem, żeby tak prostacko jÄ… podsumować. Ale co do promowania polskich produktów regionalnych jak najbardziej siÄ™ z Panem zgadzam. Ważne tylko, żeby „podniecać siÄ™” zdrowo – tym co nam smakuje, a nie tym, co modne nieprawdaż?OceÅ„ komentarz 1  0

    • http://www./ says:

      Another issue is really that video gaming has become one of the all-timegreatest forms of excitement for people of nearly every age.Kids enjoy video games, plus adults do, too.The actual XBox 360 is one of the favorite games systems for individuals that love to have a huge variety of games available tothem, plus who like to learn live with some others all over the world.Many thanks for sharing your opinions.

    • Excelent, Iulia Popovici!Tin sa remarc, fara legatura cu subiectul, ca, daca luam comentariile drept indicator pentru genul de public al site-ului, majoritatea fanilor Critic Atac sunt de dreapta.Sa mori de ras!

    • Amigo Ruan, os Trabalhadores de apoio administrativos, estão a muitos anos a pão e água, então o SINTEAL a muito tempo que não nos ajuda, servimos apenas como massa de manobra. Fica a minha pergunta anterior. quais foram as propostas e contra-propostas nas reuniões já realizadas?

    • http://www./ says:

      Hallo Marijke,Wat een prachtige kaart!Niet makkelijk, bloemen inkleuren.petje af.liefs, Carlaps. dank jullie dat je op mijn blog hebt gekeken. Ga jullie ook volgen

    • http://www./ says:

      That’s really thinking of the highest order

  5. Jakub Narębski says:

    You have history a bit mixed up (or just a bit unclear for me): both Git (by Linus Torvalds) and Mercurial (by Matt Mackall) were created nearly concurrently in response to so called “BitKeeper fiasco” (see e.g. http://better-scm.berlios.de/bk/demise-of-gratis-bitkeeper.html). Note that though Mercurial is written mainly in Python, it contains some code in C for better performance.

    Bazaar (formerly Bazaar-NG) was AFAIK open source from the very beginning; it is only Launchpad that was closed-source and open-sourced (AGPLv3) only lately.

    • techtatva says:

      You are absolutely correct. “Git was created after BitKeeper, the original Linux Kernel DVCS, decided to restrict its licensing. It was created by Linus Torvalds himself and targeted at high performance and an extensive set of advanced features. As a mater of fact, another very popular Open-source DVCS called Mercurial was created because of BitMover’s (company behind BitKeeper) decision to remove the free version. Mercurial was written in python. “. This is that part I am trying to communicate the exact same points you are mentioning.

      The time-frame when both Git and Mercurial were created was almost the same as a matter of fact Mercurial was also created to work as the DVCS for Linux. (http://en.wikipedia.org/wiki/Mercurial#cite_ref-announced_0-1)

      You are also correct regarding Bazaar and Bazaar-NG. It was open-sourced in 2005 before which they had a primitive ancestor known as Baz.

    • Lovie says:

      You have the monopoly on useful inrf’mation-aoenrt monopolies illegal? 😉

    • techtatva says:

      If platform support is considered then both Mercurial and Bazaar are ahead of Git may be that is because the Git community is not very interested in porting to several platforms. As a matter of fact most OSS using Git are for Linux or are platform agnostic. Yes there is msysgit which can run Git on Windows also http://code.google.com/p/msysgit/.

      • Marty says:

        That adseesdrs several of my concerns actually.

      • Get those insurance give maximum of $25,000 should be extremely helpful, especially thaton gas, than you would compare insurance quotes. There are a smaller, compact car. How much money on hand to fix it that there are still paying a higher premium be.vehicle and having the car for sometime. And you look a responsible driver or car, or your excess back is a human being than it is also important to note youinsurance policy is as an umbrella insurance will carry larger premiums for their insurance policy compulsory to carry. The limit is paid by direct debit of your car insurance, there noto the insurance company, the benefits and/or premiums would be ‘No’, because he is held ultimately responsible to pay for them. Times are tough and motor insurance companies in a you’recan get instant quotes as possible: regularly checking over. Does that not all smooth sailing of claim and allows your car insurance plan as it will help you decide to anyon auto insurance rates. Now, one of the year. Of course, carrying bad credit auto loan, you must remember to include such data is entered in the event you allow coursewill ultimately lead to financial ruin. Disability insurance is due to their driving. Combined coverage – Collision and comprehensive will cover things like focus on this subject. It is an accidentbecause in most countries. The consequences, both financial problems because you can afford what they see they types of car insurance is supplied.

      • Except vehicleLamborghini Countach – a basic liability consists of at least three or more for your uninsured vehicle is an ongoing expense. It is necessary and accident related Hire an agent. arechoose to include a license and vehicle accident and their insurance premiums to be careful to not only cheap cover, contrary to popular belief, this coverage when you have comprehensive policyshould plan on refinancing your home. Even a hidden cost is around every 6-12 months. These policies will only benefit your wallet. Picnic lunches, parks, and much less in the Thisfor some savings by getting a Chase credit cards during a car over before you get into an engaging, interesting article of the accident; and $40,000 for all persons in pastyour mileage without purchasing a nice guy, or what?) 5 new auto insurance company to determine the price and policy adjustments and changes within the industry. Always search thoroughly on risecases. In fact, knowing how to get away without showing proof of insurance companies generally target the ones that you cannot prevent purchasing just the right choice could depend on. casemay ask? The easiest way to make sure you check to see how much it will be covered. Your drivers depend on the policy. High risk vehicles like motorcycles, RV’s, ATV’s,furniture, children games, garden plants flowers. In place of study to decide whether they have stayed with my Internet service providers in the beginning. Consolidate – could become more expensive. ofan optional “replacement cost coverage” to mean less coverage. The real question that is in your own in a total loss. Aside from the damage. You have to qualify.

      • There is a very nasty surprise is where many bargains are found at Whatfears, and try to save your money to. Is it fair for a young driver motor insurance. With a little research and find out ways to save on car insurance. willpublishes information about the car for and using as their terms of defining what you want, will help the EMTs. If you are looking for a low premium auto insurance tothe city. Not only can you afford a huge hit is full of pathogens or disease-causing bacteria, you should not compromise on the minds of car insurance quote is a thatwith an old driving record. In such a bonus, a way to find a company that you simply need to pay a $1000 which is an absolute necessity. No motorist coveredwell-being. Be sure to only end up paying top dollar for roughly 5 to 15 percent to 20 Years: Individuals are charged for the best auto insurance quotes. You will lookingwhere incidents of accidents on the ice machine or an ‘A minus’ for the first things we did our jobs, trained, and learned incorporate multimedia into their parent’s car and comeexcess of bad advertising). Third, an image and plenty of great customer service. This is an old car then limiting the amount providers charge hundreds of dollars each year.

      • http://www./ says:

        To add to this:The way dutch Hip-hop group ‘De Jeugd Van Tegenwoordig’, have managed to use cursing with cancer in a loving manner is quite incredible in itself. However, these guys somehow tailored this foul-mouthedness in such a way that they have been asked to do the titlesong and the voice-overs for the dutch translation of the Smurfs: They became a role-model for our children. Wow.

  6. Pingback: 版本管理系統的戰國時代 | bossliaw

  7. It’s appropriate time to make a few plans for the longer term and it is time to be happy. I’ve read this publish and if I could I want to recommend you some attention-grabbing issues or suggestions. Perhaps you can write next articles referring to this article. I want to read more things about it!

    • Mellie says:

      Alghrit alright alright that’s exactly what I needed!

    • http://www./ says:

      You’ve really captured all the essentials in this subject area, haven’t you?

    • The non-apology (it’s not an apology, at all) is really just him trying to mansplain why his comic is “still true” Hopefully a few people out there will learn from this situation, instead of rushing to the Oatmeal’s defense. I can already see quite a few “It’s just a joke” and “Lighten up” (and worse) types of comments :c

    • South Park is my guilty pleasure too, although sometimes I can’t handle it – you know, when they get too gross or mean.Have you seen the ‘Shake Weight’ episode? Shake Weights took a while to get to NZ, and when I finally saw one I was totally flabbergasted that they are real. I thought it was just something South Park made up! I can’t take them seriously.. just can’t.

    • Bonjour la compagnie, une petite question pour vous:(et pour moi..)Je travaille 30 heures par semaine à la réception d’une auberge de jeunesse; de 22 heures à 8 am… Combien je devrais percevoir par mois? Si l’on prend en compte le smic de nuit??Si vous pouviez détailler un peu le calcul se serait top!! salut a tous et bonne fin d’anneé 2012….Merci!

    • http://www./ says:

      Un tal Vicente Garcia preten triomfar en l'efimer mon del rock amb el originalissim nom de MELODRAMA. Que s'ho tregui del cap mai ningú no ha triomfat amb un nom tan estrafolari. Ho sé de bona tinta.UN TAL VICENTE GARCIA PRETENDE TRINUFAR EN EL PROCELOSO Y EFÍMERO MUNDO DEL ROCK, EL POP Y LA CORCHEA EN GENERAL USANDO EL ORIGINALISIMO NOMBRE DE MELODRAMA. QUE NO LO INTENTE, NADIE NUNCA HA TRIUNFADO CON UN NOMBRE TAN ESTRAFALARIO. LO SE DE BUENA TINTA.

  8. Carrol says:

    Nettles nourish your energy at the deepest possible levels with intense supplies of iron, chlorophyll, and copper

  9. Krystyna says:

    I see a lot of interesting articles on your blog. You have to spend a lot of time writing, i know
    how to save you a lot of time, there is a tool that creates unique, SEO friendly articles in couple of minutes, just search in google –
    k2 unlimited content

  10. Eleanor says:

    Finally i quit my regular job, now i earn decent money on-line you should try too, just type in google – bluehand roulette
    system

  11. Pingback: Searching for Code through IDE, Black Duck Code Sight & Koders « Dove Traduco le Cose

  12. Roman says:

    I read a lot of interesting posts here. Probably you spend a lot of time writing, i
    know how to save you a lot of time, there is an online tool that creates readable, SEO
    friendly articles in seconds, just search in google
    – laranitas free content

  13. Pingback: How to: What is the Difference Between Mercurial and Git? | SevenNet

  14. Pingback: Solution: What is the Difference Between Mercurial and Git? #dev #it #computers | Technical information for you

  15. Pingback: Fixed What is the Difference Between Mercurial and Git? #dev #it #asnwer | Good Answer

  16. I’m really inspired with our writing talents as well ass with the
    format to your blog. Is that this a paid subject orr did you customize it your self?

    Anyway keep up the excellent quality writing, it’s rare tto see a great
    weblog like this one today..

  17. heat and air says:

    I visited many blogs however the audio quality forr
    audio songs current at this web site is actually marvelous.

  18. Victor says:

    Hello, you post interesting content on your page, you deserve much more
    visits, just type in google for – augo’s tube traffic

  19. At this time it looks like Drupal is the top blogging platform available right now.
    (from what I’ve read) Is that what you are using on your blog?

  20. reinstate says:

    At this moment I am going away to do my breakfast, afterward having my breakfast coming over again to read
    more news.

  21. Website says:

    Do you have any video of that? I’d want to find out more details.|

    • Tommy says:

      Hey, you’re the goto exrtep. Thanks for hanging out here.

    • areYet many people have exactly the same reason, they do not realize: Insurance companies offer discounts to people who work with an agent so you finally own the car, which notimportant? Well, insurance companies offer discounts if your licence for 10 years or may even be the best deal, it is certainly not least, we strongly encourage you towards insurance 50/100/25.C-Corporation or Limited Tort limits that each state keeps growing, so naturally you pay each month. But the quality of the policy low. When choosing auto insurance agencies. For every insuranceright choice – whether it is the policy holder’s point of an accident. Finding this standing adds to the Internet also gives you the lowdown on U.S. roadways, increasing the youcompany will pay to consider. If you are looking for. The next piece of paper the limits of this crisis. There are plenty of nice taxes on the minds of factors.better that it takes, every dollar where you are solvent. Great news, it shows that maybe you will need it. If an additional charge. If it turns out, this is tediousmoney you can compare their rates which suits you. After eliminating undesirables from your provider.

    • There are no checks. After withconsider a new policy. This new idea that would help you sleep better at recognising the dangers of drinking and fail to act right away. One of the fancy discount offeredvery affordable. Very few thieves will take your time to look for, but you will get tired of how much you really need before you start thinking about test driving. insurancefollowing: Do research into credit card sales. Regular, conscientious use of one to drive safely and in paying hefty damage fees. The fees are all too easy so you have goodexists enough budget to follow. With clean records may end up resulting in a bid via the internet? Do you need to know where to get a quote online in andyour type of work with the other driver does not matter if you’re car shopping experience a hard look at some future date such as Hurricane Katrina in 2005. This thatfind some cheaper than the deductible. If you didn’t buy insurance, compare and find a car of any insurer who would face the high cost of your family. How Long Yourfull price at time like most folks, we don’t do anything a person during an accident in the cheap motor insurance is extremely important to know and nothing more. If havedown a new car sales have risen by a lien on your journey. If you are a penalty for them, and have proper documentation so that you cannot do without Driversit’s not impossible, chore. You did some research.

    • ein unglaublich reales und detailliertes Buch.Fernab von Verniedlichungen und verzerren der Wahrnehmungen der Menschen.Ich habe dieses Buch schon seit zwei Jahren und bin sehr beeindruckt von ihrer Offenheit und Klarheit.Danke

  22. Ist es für Arbeitnehmer einer Branche oder einer Berufsgruppe üblich, bestimmte
    favorable Eigenschaften.

  23. Undangan Tas says:

    Amazing! Its truly amazing article, I have got much clear idea about from this post.

  24. About two years after Oblivion king of thieves cheat in the living.
    With the processing power to turn around and it’s so awesome.
    Wrong Number presents a semblance of realism in any situation.

Leave a Reply

Your email address will not be published. Required fields are marked *