Home > Programming > DSCM: Mercurial or Bazaar?

DSCM: Mercurial or Bazaar?

I just recently switched over to using Mercurial for all SCM needs. I figured that the Mercurial team had solved the rename problem by now. However, I just noticed Mark Shuttleworth’s entry on the topic. It seems Bazaar could still be in the running as the DSCM of choice. However with Sun choosing it for OpenSolaris and now OpenJDK it kinda becomes inevitable for Java developer to go with Mercurial. After all, Mercurial has Eclipse and Netbeans plugins. But then again, I love to restructure my tree… Then again I don’t merge with anyone right now ;).

Why MoinMoin chose Mercurial

Why OpenSolaris chose Mercurial (GIT and Bazaar being the other finalists)

Why Mozilla chose Mercurial – Bazaar and Mercurial were the final 2

On the whole, it seems that GIT lacks the win32 support and is a bit weird in that it doesn’t explicit track renames and guesses about them. Bazaar has some performance issues but otherwise is a good candidate. Mercurial does copy+delete renames but otherwise has great performance, portability and usability.

I’m happy with my choice of Mercurial but Bazaar will be the one to watch as they work towards 1.0 focusing on performance and documentation improvements.

About these ads
Categories: Programming Tags: , , ,
  1. brendan
    June 13, 2007 at 18:29

    Mark’s comment about Mercurial’s rename support was pretty misleading. Mercurial does track rename info explicitly, and makes use of it for things like merge. See tonfa’s reply to Mark’s post for more information. I’m not sure why Mark wrote what he did.

  2. June 14, 2007 at 23:54

    Are you sure?

    I read that hg wants bzr’s merging edits across renames support.

    That was a year ago. Maybe Mercurial implemented it. That was what I was getting at. I figured they would have done it by now. If the information is all there, after a rename, the “hg log” command ought to show the rename rather than the copy+remove. Otherwise it leaves you wondering.

    In addition tonfa’s comments about Mercurial’s heuristic handling of directory renames is not encouraging. I don’t want my SCM to use heuristics… even if Linus says that’s adequate – even better!.

    I’d be interested to get to the bottom of this. Part of the team is offshore at my current client and I have been recommending upgrading to Subversion from ClearCase LT 2003. However, since noticing a few other issues – particularly for the offshore team, I am wondering whether to push for Mercurial is the better way to go – hence I am putting it on trial at the home office. This is a Java shop so IDE support is a big plus.

  3. brendan
    June 18, 2007 at 02:17

    As you note, that posting was a year ago. Mercurial’s merge-across-rename support has been complete for some time now. The log command does display the information when you use the –follow flag. So the annotate and grep commands.

    Mercurial does not track directories explicitly though. So the way a directory rename works is that if all of the tracked files in a directory move to a new directory, then when you update or merge that revision, all of the files including untracked files will be moved. I would agree that it’s not perfect, but I don’t think it’ll produce any particularly bad results very often. At worst you just have to move a few files manually after the merge. Since these files have no merge conflicts (if they did, the merge machinery would discover it and handle it for you), it’s a pretty trivial operation in my opinion.

    As for IDE integration, I think that’s still young. I do know that an eclipse plugin has been started, as well as a tortoise-like GUI for windows.

  4. Tom
    February 1, 2010 at 16:28

    brendan: “I’m not sure why Mark wrote what he did.”

    Mark wants the directory renaming (as well as file renaming) to be something that “just works” always.

    I don’t consider his remarks misleading. Contrast your statement about Mercurial: “… I don’t think it’ll produce any particularly bad results very often.” In other words, sometimes it could produce particularly bad results.

    Mark considers that risk to outweigh any speed differences between Mercurial and Bazaar (and even those have been reduced over time). Renaming directories (as well as files) should “just work” all the time.

  1. No trackbacks yet.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

Follow

Get every new post delivered to your Inbox.

%d bloggers like this: