<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>SteveStreeting.com &#187; DVCS</title>
	<atom:link href="http://www.stevestreeting.com/tag/dvcs/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.stevestreeting.com</link>
	<description>Man bites Ogre</description>
	<lastBuildDate>Sat, 24 Dec 2011 13:08:06 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.1.4</generator>
		<item>
		<title>Introducing: SourceTree</title>
		<link>http://www.stevestreeting.com/2010/10/26/introducing-sourcetree/</link>
		<comments>http://www.stevestreeting.com/2010/10/26/introducing-sourcetree/#comments</comments>
		<pubDate>Tue, 26 Oct 2010 16:24:20 +0000</pubDate>
		<dc:creator>Steve</dc:creator>
				<category><![CDATA[Business]]></category>
		<category><![CDATA[Cocoa]]></category>
		<category><![CDATA[Development]]></category>
		<category><![CDATA[Objective C]]></category>
		<category><![CDATA[Personal]]></category>
		<category><![CDATA[Tech]]></category>
		<category><![CDATA[DVCS]]></category>
		<category><![CDATA[Git]]></category>
		<category><![CDATA[Mac]]></category>
		<category><![CDATA[Mercurial]]></category>
		<category><![CDATA[OS X]]></category>
		<category><![CDATA[sourcetree]]></category>
		<category><![CDATA[vcs]]></category>
		<category><![CDATA[version control]]></category>

		<guid isPermaLink="false">http://www.stevestreeting.com/?p=2845</guid>
		<description><![CDATA[I&#8217;m pleased to announce that I&#8217;m finally ready to make my first fully-fledged commercial Mac OS X application available to the world! SourceTree is a user-friendly Mac OS X front-end for Mercurial and Git, the two most popular distributed version control systems used today. The goal was to create a single tool which could deal [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.sourcetreeapp.com" target="_blank"><img class="alignright size-thumbnail wp-image-2846" title="icon" src="http://www.stevestreeting.com/wp-content/uploads/2010/10/icon-150x150.png" alt="" width="150" height="150" align="right" /></a>I&#8217;m pleased to announce that I&#8217;m finally ready to make my first fully-fledged commercial Mac OS X application available to the world!</p>
<p><strong><a href="http://www.sourcetreeapp.com" target="_blank">SourceTree</a></strong> is a user-friendly Mac OS X front-end for <a href="http://mercurial.selenic.com/" target="_blank">Mercurial</a> and <a href="http://git-scm.com/" target="_blank">Git</a>, the two most popular distributed version control systems used today. The goal was to create a single tool which could deal with both systems efficiently, and to give a developer quick and intuitive access to the things (s)he needs to just get on with building software.</p>
<p>I thought I&#8217;d answer a few background questions on this that I get asked on occasion:</p>
<p><strong>Why Mercurial AND Git?</strong></p>
<p>Other apps tend to concentrate on just one version control system, so why am I supporting two? Well, as a developer I&#8217;m regularly coming across projects from both sides of the fence, and in practice I find I need to use both fairly regularly. I personally chose Mercurial for my own projects (and discussed why <a href="http://www.stevestreeting.com/2009/11/06/dvcs-score-card/">here</a>), but I still use Git when dealing with other projects, and spend a fair amount of time hopping between the two. It struck me that even though they have their differences, they are both based on the same <a href="http://en.wikipedia.org/wiki/Distributed_Version_Control_System" target="_blank">distributed principles</a>, so having to use two separate tools was just unnecessary. I wanted a single tool which provided a common interface where that made sense, while still exposing the things they do differently where that was useful too. <a href="http://www.sourcetreeapp.com" target="_blank">SourceTree 1.0</a> is my first attempt at that.</p>
<p><strong>Why only Mac OS X?</strong></p>
<p>There were actually multiple reasons for this choice:</p>
<ol>
<li>I wanted to learn Objective-C and Cocoa on a real project</li>
<li>I know from experience that designing for multiple platforms can be a distraction, with more time spent on compatibility issues, and less on functionality &#8211; and that&#8217;s before you even consider the compromises  you have to make, particularly on UI conventions which are far from uniform across platforms. I&#8217;ve been a multi-platform developer for more than 10 years, and for a change I just wanted to focus on the end user results and nothing else. I&#8217;m aware that schedules slip very easily when you overcomplicate, and I&#8217;m already supporting multiple DVCS systems (something I consider to be an important feature point), so I deliberately chose to keep this element simple.</li>
<li>Mac OS X has become my own platform of choice for most things now. The combination of stability, user-friendliness, Unix underpinnings and well designed hardware match my current needs perfectly. I&#8217;m done with the &#8216;some assembly required&#8217; PCs that I loved tinkering with over the past 15 years</li>
</ol>
<p><strong>What about Subversion?</strong></p>
<p>A few people have asked me if I plan to add Subversion support too. I actually did intend to originally, until I realised how much time it was going to take to just do a decent job on Mercurial and Git. Within the time constraints, I focussed on the subject areas that I felt I could contribute most to &#8211; there are already quite a few Subversion tools out there for Mac OS X, but Mercurial and Git are much less well served, so that&#8217;s where I focussed my efforts.</p>
<p>I still have Subversion support tentatively on my work plan, but it&#8217;s not top of the list. I think it&#8217;s better to do your most important features well before diversifying. Plus, there are problems with Subversion &#8211; it&#8217;s very, very slow compared to Mercurial and Git, so to match the performance in SourceTree of things like the interactive searches and dynamic refreshing / log population I&#8217;d probably have to do a ton of extra caching just so the user wasn&#8217;t sat tapping their fingers.</p>
<p><strong>Edit:</strong> I made my decision on this: I don&#8217;t plan to support local Subversion, but to support operating with Subversion servers with Mercurial and Git locally via hgsvn and git-svn.</p>
<p><strong>Why didn&#8217;t you make it open source?</strong></p>
<p>Sorry folks, while I love contributing to open source (I&#8217;ve done a bit on SourceTree too, sending a patch back to BWToolkit), making it work as a business is very hard indeed. I half-killed myself trying to combine being an open source project leader and doing other commercial activities at the same time, so now I&#8217;m trying a more traditional approach. One thing I learned in the last few years is that there are some sectors &amp; application types where being an open source maintainer is very compatible with also running a business based on that project, and there are others where you can really only do one or the other simultaneously without flaming out. Sucks, but there it is <img src='http://www.stevestreeting.com/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /> </p>
<p><strong>What&#8217;s Next?</strong></p>
<p>I have a <a href="http://www.sourcetreeapp.com/roadmap/" target="_blank">public, official roadmap</a> for SourceTree and encourage users to suggest things they think should be on there, via the <a href="http://www.sourcetreeapp.com/support/" target="_blank">support system</a>. I learned from running an open source project for 10 years that being open about your plans can be a big benefit &#8211; users like to know where things are likely to be going, and often have better ideas than the developer on what could do with a bit more spit and polish. They can also tell you what&#8217;s important to them, which is crucial for prioritising &#8211; as developers we tend to get carried away with things we want to work on, but in the end, it&#8217;s scratching the customer&#8217;s itch that matters most.</p>
<p>And while I&#8217;m really quite proud of SourceTree 1.0, there are plenty of features I&#8217;d like to continue to add, and definitely more room for some totally unnecessary beautification which I didn&#8217;t have time for in the first release. Hey, this <em>is</em> OS X <img src='http://www.stevestreeting.com/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /> </p>
<p>SourceTree is available now on a 21-day trial license. <a href="http://www.sourcetreeapp.com" target="_blank">Go get it already</a> <img src='http://www.stevestreeting.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
]]></content:encoded>
			<wfw:commentRss>http://www.stevestreeting.com/2010/10/26/introducing-sourcetree/feed/</wfw:commentRss>
		<slash:comments>14</slash:comments>
		</item>
		<item>
		<title>hgsubversion &#8211; dropping old history during conversion (mod)</title>
		<link>http://www.stevestreeting.com/2009/11/24/hgsubversion-dropping-old-history-during-conversion-mod/</link>
		<comments>http://www.stevestreeting.com/2009/11/24/hgsubversion-dropping-old-history-during-conversion-mod/#comments</comments>
		<pubDate>Tue, 24 Nov 2009 20:24:22 +0000</pubDate>
		<dc:creator>Steve</dc:creator>
				<category><![CDATA[Development]]></category>
		<category><![CDATA[OGRE]]></category>
		<category><![CDATA[Open Source]]></category>
		<category><![CDATA[DVCS]]></category>
		<category><![CDATA[hgsubversion]]></category>
		<category><![CDATA[Mercurial]]></category>
		<category><![CDATA[ogre]]></category>

		<guid isPermaLink="false">http://www.stevestreeting.com/?p=2418</guid>
		<description><![CDATA[I&#8217;ve already posted about my experiences with Git and Mercurial, the end result of which was a vastly increased respect for Git but a basically confirmed preference for Mercurial, based on ease of use, platform consistency and resilience. Mercurial&#8217;s conversion tools are really quite good &#8211; the core tools worked fine but I was impressed [...]]]></description>
			<content:encoded><![CDATA[<p><img class="alignright size-full wp-image-2420" title="mercurial" src="http://www.stevestreeting.com/wp-content/uploads/2009/11/mercurial.gif" alt="mercurial" width="182" height="227" />I&#8217;ve <a href="http://www.stevestreeting.com/2009/11/06/dvcs-score-card/" target="_blank">already posted</a> about my experiences with Git and Mercurial, the end result of which was a vastly increased respect for Git but a basically confirmed preference for Mercurial, based on ease of use, platform consistency and resilience.</p>
<p>Mercurial&#8217;s conversion tools are really quite good &#8211; the core tools worked fine but I was impressed by <a href="http://bitbucket.org/durin42/hgsubversion/wiki/Home" target="_blank">hgsubversion</a>&#8216;s speed and that it seemed to just work, in both initial conversion and pulling subsequent updates. It was missing a couple of features that I wanted though &#8211; firstly the ability to reflect merge points between branches during the conversion, and secondly to be able to &#8216;squash&#8217; ancient history down to a simple snapshot to save space.</p>
<p>At <a href="http://www.ogre3d.org/" target="_blank">OGRE</a>, we&#8217;d carried forward all our history from CVS to Subversion and as such have almost 8 years of history, including a couple of file reorganisations. Mercurial&#8217;s storage efficiency falls down compared to Git when files are moved around, because a file stored in more than one place in the tree over the history of the project is physically stored multiple times too, whilst Git stores the content only once with pointers from the various locations / history points. Most of this overhead could be removed just by eliminating old history we didn&#8217;t need anymore &#8211; history that does no harm in Subversion since only the server holds it, but does cause unwanted overheads in a DVCS since every user gets the entire repository. Removal of history is something that Mercurial shuns &#8211; rightly so in the case of public repositories but in these rare cases it would be nice if there was a tool for removing old history; again Git allows this but it has to be used with care. In the absence of that, doing it at conversion seemed the best way.</p>
<p>I asked about these things in the hgsubversion community, but the tradition of open source is that if you really want something urgently, you know where the code is <img src='http://www.stevestreeting.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' />  Mercurial is really nice when it comes to hacking because it&#8217;s all Python; so there&#8217;s a nice unified API in one place that you can refer to &#8211; that&#8217;s one of the reasons I like it over Git which is far more fragmented in technology terms. I&#8217;m not a Python guru by any means, but I managed to implement both these features &#8211; I did the &#8220;mergemap&#8221; support a little while ago and added the &#8220;skipto&#8221; option today &#8211; it&#8217;s called that because &#8220;skipto&#8221; was already referred to in the hgsubversion code but it had no implementation.</p>
<p>The result is that the <a href="http://bitbucket.org/sinbad/ogre/" target="_blank">OGRE Mercurial repository</a> with only the last ~3 years of history (back to when the v1.4 branch was created) is now only 74MB, rather than the 206MB of the original, complete conversion (in comparison Git was 116MB for the whole thing). By dropping the history I&#8217;ve removed most of the instances of reorganisation which is where most of the space has gone. I  hope eventually that Mercurial adds a utility to deal with stripping ancient history (right now, you can only strip branches) but this solves my primary conversion issue. Since this new repo can be kept in sync in a very lightweight fashion with the existing Subversion repo, I&#8217;ll be periodically updating it and doing more tests to reassure myself that the content really is ok.</p>
<p>If you&#8217;d like to get my custom version of hgsubversion with these features, it&#8217;s here: <a href="http://bitbucket.org/sinbad/hgsubversion/" target="_blank">http://bitbucket.org/sinbad/hgsubversion/</a>. I make no promises that it&#8217;s error-free, use at your own risk. It currently assumes that you&#8217;re using the standard Subversion layout, are converting from the root of that and have the &#8216;svn&#8217; command on your path.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.stevestreeting.com/2009/11/24/hgsubversion-dropping-old-history-during-conversion-mod/feed/</wfw:commentRss>
		<slash:comments>5</slash:comments>
		</item>
		<item>
		<title>DVCS Score Card</title>
		<link>http://www.stevestreeting.com/2009/11/06/dvcs-score-card/</link>
		<comments>http://www.stevestreeting.com/2009/11/06/dvcs-score-card/#comments</comments>
		<pubDate>Fri, 06 Nov 2009 18:23:49 +0000</pubDate>
		<dc:creator>Steve</dc:creator>
				<category><![CDATA[Development]]></category>
		<category><![CDATA[OGRE]]></category>
		<category><![CDATA[DVCS]]></category>
		<category><![CDATA[Git]]></category>
		<category><![CDATA[Mercurial]]></category>
		<category><![CDATA[ogre]]></category>

		<guid isPermaLink="false">http://www.stevestreeting.com/?p=2354</guid>
		<description><![CDATA[So, I&#8217;ve just about completed my practical experiments &#38; review of Mercurial and Git. In the end, I had far too many separate notes and sets of experiences to post, so I boiled the argument down into the 10 most important factors to me, and scored Mercurial and Git on a scale of 1-5 based [...]]]></description>
			<content:encoded><![CDATA[<p>So, I&#8217;ve just about completed my practical experiments &amp; review of Mercurial and Git.</p>
<p>In the end, I had far too many separate notes and sets of experiences to post, so I boiled the argument down into the 10 most important factors to me, and scored Mercurial and Git on a scale of 1-5 based on what I&#8217;d found when using them. Here are the (annoying) results:</p>
<table border="1" cellspacing="0" cellpadding="5">
<tbody>
<tr>
<td><strong>#</strong></td>
<td><strong>Criterion</strong></td>
<td><strong>Git</strong></td>
<td><strong>Hg</strong></td>
</tr>
<tr>
<td>1</td>
<td>Ease of use &#8211; command line</td>
<td style="text-align: center;">4</td>
<td style="text-align: center;">5</td>
</tr>
<tr>
<td>2</td>
<td>Ease of use &#8211; GUI</td>
<td style="text-align: center;">4</td>
<td style="text-align: center;">4</td>
</tr>
<tr>
<td>3</td>
<td>Platform support &#8211; core</td>
<td style="text-align: center;">3</td>
<td style="text-align: center;">5</td>
</tr>
<tr>
<td>4</td>
<td>Platform support &#8211; GUI</td>
<td style="text-align: center;">4</td>
<td style="text-align: center;">4</td>
</tr>
<tr>
<td>5</td>
<td>Web Host Functionality</td>
<td style="text-align: center;">5</td>
<td style="text-align: center;">4</td>
</tr>
<tr>
<td>6</td>
<td>Reliability &amp; error handling</td>
<td style="text-align: center;">3</td>
<td style="text-align: center;">5</td>
</tr>
<tr>
<td>7</td>
<td>Storage efficiency</td>
<td style="text-align: center;">5</td>
<td style="text-align: center;">3</td>
</tr>
<tr>
<td>8</td>
<td>Run-time performance</td>
<td style="text-align: center;">5</td>
<td style="text-align: center;">5</td>
</tr>
<tr>
<td>9</td>
<td>Flexibility</td>
<td style="text-align: center;">5</td>
<td style="text-align: center;">4</td>
</tr>
<tr>
<td>10</td>
<td>OGRE Community support</td>
<td style="text-align: center;">5</td>
<td style="text-align: center;">4</td>
</tr>
<tr>
<td></td>
<td><strong>Totals</strong></td>
<td style="text-align: center;"><strong>43</strong></td>
<td style="text-align: center;"><strong>43</strong></td>
</tr>
</tbody>
</table>
<p>I&#8217;ll explain the scores, and my conclusion, after the jump.</p>
<p><strong><span id="more-2354"></span>1. Ease of use &#8211; command line</strong></p>
<p>This criterion boils down to how easy is it to learn to do <em>all </em>the operations required of a typical developer, many of which I&#8217;ve <a href="http://www.stevestreeting.com/2009/08/06/getting-more-structured-with-my-dvcs-tests/">listed in a separate thread</a>, how consistent and intuitive those commands are, how natural the defaults are, and how easy it is to screw something up by accident. This is by nature a subjective measure. While Git improved greatly in my perception during the course of the evaluation, there is absolutely no doubt that the command-line of git takes more time to learn to operate effectively than Mercurial does. I deliberately learned Git first to avoid being biased by a command set that was closer to what I was used to, and grew to be happy with most of the Git commands, but it took me longer and I had to refer to the help and Google for things more often. The included help in both is good, but git has a lot more options (hence the win on flexibility later) and lots more discussion on edge cases and how the physical repository implementation is affected, which may be interesting technically but can cloud the issue when you&#8217;re trying to learn how to do something. Unusual terminology also confuses people from other systems &#8211; &#8220;git reset &#8211;hard HEAD&#8221; is simply not as intuitive as &#8220;hg revert &#8211;all&#8221;  for the migrators. I felt more comfortable with Mercurial&#8217;s command-line faster than I did in Git, despite learning Git first. I did, however, feel that I could use Git fairly happily after going through the learning process, and my attitude towards it moderated after some experience &#8211; this is why there is only a single point difference between them &#8211; if you&#8217;re at the start of the learning process Git is probably a 3 rather than a 4.</p>
<p><strong>2. Ease of use &#8211; GUI</strong></p>
<p>Linux users typically care less about this than those on Windows and Mac, and since I rarely use Linux on the desktop I&#8217;ve concentrated on Windows and Mac here. I tried <a href="http://code.google.com/p/tortoisegit/" target="_blank">TortoiseGit</a>, <a href="http://gitx.frim.nl/" target="_blank">GitX</a>, <a href="http://bitbucket.org/tortoisehg/stable/wiki/Home" target="_blank">TortoiseHg</a> and <a href="http://bitbucket.org/snej/murky/wiki/Home" target="_blank">Murky</a> (<a href="http://www.syntevo.com/smartgit/index.html" target="_blank">SmartGit</a> is another but it wasn&#8217;t considered stable when I was looking). In practice I found both systems to have shortcomings; on Mac the GUIs are still quite limited in functionality, and on Windows there are some things that work better in TortoiseGit (it feels like other Tortoises so initial impressions are superior to TortoiseHg which is a different layout), but TGit also has some bugs (such as not listing all branches in Switch if there&#8217;s more than about 20) and relies on msysGit which is not ideal especially when you need to abort an action and it leaves a git.exe lying around locking files. In practice they&#8217;re all about equal in their imperfections, no clear winner. I&#8217;m sure they&#8217;ll both improve over time but both are usable now, with users needing to drop to the command line for more complex tasks (see point 1).</p>
<p><strong>3. Platform support &#8211; core</strong></p>
<p>This is about whether the core toolset runs well across at least Windows, Linux and Mac OS X. This covers not only the ability to run on each of the platforms consistently, but also to exchange data between the platforms without issues and deal with line ending differences etc. Git came of worst here, because it is inherently designed to require a Unix-like environment, built as it is on common Unix tools like the shell and perl. On Windows it requires msysGit which in most cases works (I tested with 1.6.4 and 1.6.5) but is both significantly slower than under Linux &#8211; something you only notice for large operations but it&#8217;s up to a factor of about 6 in my tests &#8211; and still has bugs. git-svn for example is completely unusable on Windows in my experience against non-trivial repositories &#8211; the Ogre repository killed it consistently. Also the core Git developers openly admit that they don&#8217;t care much about Windows support, so commitment to the platform isn&#8217;t there. Mercurial on the other hand runs on Python and in my tests operated identically on all platforms, and is officially supported wherever Python runs. Both systems handled automatically converting line endings and did a better job than Subversion (which requires properties per file).</p>
<p><strong>4. Platform support &#8211; GUI</strong></p>
<p>So does either system support the platform range better than the other via the GUI? Not really &#8211; as mentioned in the ease of use section they&#8217;re both pretty good but still a little flawed in places. On Windows you still require msysGit even with a GUI which makes Git a little slower than on other platforms, but TortoiseGit is surprisingly good considering the vibe of general disinterest in Windows around Git. GitX and Murky are competent if limited on Mac OS X. Both systems have a core Tcl/Tk interface if you really need it, but honestly anyone in the slightest bit sensitive to nice GUI design won&#8217;t want to touch them with a 20 foot barge pole, they&#8217;re <em>ugly </em>- Tcl/Tk makes Windows 3.0 look shiny in comparison. No clear winner here.</p>
<p><strong>5. Web Host Functionality</strong></p>
<p>A few online services have sprung up to support the DVCS workflows better than simple hosting on Sourceforge or Google Code. Everyone seems to talk about <a href="http://www.github.com" target="_blank">GitHub</a> all the time, but while it&#8217;s very pretty, functionally it&#8217;s soundly eclipsed by <a href="http://www.gitorious.com" target="_blank">Gitorious</a> which has considerably more robust support for dealing with merge / pull requests, handling them much like a patch tracker but with repository-aware, multi-revision URLs and inline reviewing instead of patch files. They also allow integration of contributor license agreements. GitHub in contrast only allows fire-and-forget pull requests or generalised browsing of commits people have made to other forks, which is not as useful.</p>
<p><a href="http://www.bitbucket.org" target="_blank">BitBucket</a> (for Mercurial) is functionally pretty much the same as GitHub (including the fire-and-forget merge/pull requests and general fork lists), except that it&#8217;s not quite as flashy. If we were comparing GitHub and BitBucket, the scores would be the same since aesthetics are not very important in the grand scheme of things, but Gitorious ups the ante, which is why Git wins in this category. I&#8217;ve actually talked to the guys at BitBucket, who are extremely friendly and eager to help, and Gitorious-style merge requests are on their TODO lists. They even offered to bump it up their priority lists if it was important to us. Very helpful chaps, but Gitorious still has to win based on the current status.</p>
<p>As an aside, it&#8217;s also worth noting that <a href="https://launchpad.net/" target="_blank">Launchpad</a> is also extremely good in the merge request tracking area, on par with Gitorious. I dropped Bazaar from my evaluation due to lack of time and because it&#8217;s the least popular of the 3 in our community by a massive margin (and also, I don&#8217;t like the branch containment model they use very much), but Holger played with it and it&#8217;s clear that Launchpad deserves a mention for nailing this feature set very well. GitHub may be the poster child, but functionally others deserve more attention.</p>
<p><strong>6. Reliability and Error Handling</strong></p>
<p>As a wise man once said, sh*t happens. How easy a system is to break, and how it behaves when things go wrong is just as important as how well it works under normal operating circumstances, especially for something as critical as a source control system. I didn&#8217;t specifically go out of my way to cause problems, but during my many use cases I did encounter some sticking points, which was precisely the point.</p>
<p><em>Q. How often did problems occur?</em> A. On Mercurial, I never had a crash, on any platform, that I didn&#8217;t accidentally cause myself. The two crash incidents I had were during conversion from Subversion, and were caused by firstly an rsync kicking in and changing the source Subversion file system under the feet of the conversion process, and secondly when I killed the process manually because I wanted to interrupt it. So in essence, I have yet to see Mercurial fail unless I break it. On Git, I normal operations behaved fine but during conversion from Subversion I had many problems. Git 1.6.4 and 1.6.5 on Windows regularly crashed mid-conversion, as did Git 1.5 on Linux. Git 1.6.5 on Linux behaved better, but only if you upgraded the (admittedly old) Subversion 1.3 repository to 1.5 or 1.6 first. Mercurial on the other hand seemed to cope with any combination I threw at it, on any platform.</p>
<p><em>Q. How good was the error reporting, and how easy was it to recover?</em> On Mercurial, when I did get a crash (self-inflicted) I got a full Python stack trace with an exception message which was consistently useful, allowing me to quickly rectify the issue. The repository was also valid even in those cases. On Git, all the crashes I had on Windows and Linux simply resulted in the process terminating with no message. I only managed to figure out how to resolve the problems through trial and error, Git was absolutely no help. The repository left behind after these crashes was corrupt.</p>
<p>So, my personal experience was that Mercurial was very robust, and in the rare case of a problem it reported it well. Git was ok most of the time, but some operations were fragile and for example only a very specific version &amp; platform worked for converting the OGRE repository. When Git did fail, my experience was that it didn&#8217;t report any useful errors and it basically left you high &amp; dry, scrabbling on the net for answers. Mercurial wins this one outright based on my experiences.</p>
<p><strong>7. Storage Efficiency</strong></p>
<p>A simple one to measure &#8211; after converting the 375MB OGRE repository to both systems, and before any custom pruning, Mercurial was about 200Mb and Git about 180Mb. A manual pruning operation by community member guyver6 brought the Git repository down to 116Mb; after pruning out branches in Mercurial I only managed to remove about 7Mb. It appears that the primary reason for that is that moved binaries end up getting stored twice in Mercurial, while Git only stores them once once the data has been packed. Mercurial always packs its data as you operate on the repository, while Git lets its storage get sub-optimal in size while you&#8217;re working on it in order to give you maximum run-time performance, and &#8216;git gc&#8217; needs to be run every so often (some commands do this automatically) to re-pack the data for storage efficiency; which is best depends on your point of view, whether you prefer a uniform behaviour or a split behaviour. But overall, Git wins here. In OGRE we actually have a number of moved binaries in our history which Mercurial clearly does not store as efficiently as Git does.</p>
<p><strong>8. Run-time performance</strong></p>
<p>This was a bit of a mixed bag. I found that Git on Windows was a poor performer on local batch operations that were not constrained by the network, compared to Mercurial. On Linux or OS X performing local operations, performance was practically indistinguishable between the two. Bulk operations that did require network access were a little faster using Git, but not by much. When it came down to everyday operations, the slightly slower msysGit for local operations, and the slightly slower network performance of Mercurial, were barely perceptible. A wash, both systems are fine.</p>
<p><strong>9. Flexibility</strong></p>
<p>When you need to do unusual activity X, can you do it? In Git, the answer is almost always &#8216;yes&#8217; &#8211; it has an enormous number of commands and options and doesn&#8217;t really stop you from doing anything, even if it&#8217;s a bad idea. Mercurial on the other hand defaults to being quite strict, but there are a number of extensions, both official and unofficial, that can bring the functionality fairly close to Git, but not all the way. A few examples:</p>
<p>Local branches: this is a very useful feature of Git, where you can create lightweight branches in your local repository that you can use for experiments or patch processing without having them become a permanent part of the upstream history. Mercurial branches are all permanent by default, unless you use the LocalBranch extension which is not official. You can replicate the behaviour to a degree with Queues, which is official, but it&#8217;s more complicated. Git is better here.</p>
<p>History Modification: changing history is a very bad idea if you&#8217;re upstream of anyone else, but in a local private repository it can sometimes be useful. Git provides features such as rebase &#8211;interactive in which you can squash together and reorder commits to reorganise them before upstream submission, and filter-branch to make wholesale changes to the history, for example post-conversion to simplify the repository. Mercurial has basic support for some history modification (MQ again, and unofficial extensions like histedit), but they are not as flexible. Most of the time this isn&#8217;t an issue, but occasionally it can be limiting &#8211; for example I have not so far found a way to remove history before a certain date (or collapse revisions together before a certain date) &#8211; the unofficial histedit and collapse extensions do not work for this and MQ won&#8217;t let me import regions for qfolding that exist before branches are taken (which is what I want to do &#8211; I need my more recent branch history, I don&#8217;t need the old stuff). I don&#8217;t understand this restriction, I&#8217;ve already stripped all the early branches so the early history is entirely linear, why should it care that there&#8217;s a branch taken later on?</p>
<p>So, Git wins here. In everyday use you won&#8217;t care about this, which is why there&#8217;s only a single point between the scores when otherwise Git might deserve a 2-point lead here, but certainly when you&#8217;re doing uncommon things Mercurial puts more barriers in your way. In day-to-day operations that&#8217;s probably a good thing, since it encourages you not to do stupid things. But when you have a specific need to do something for a very good but rare reason, it&#8217;s annoying when you can&#8217;t.</p>
<p><strong>10. OGRE Community Support</strong></p>
<p>We <a href="http://www.ogre3d.org/forums/viewtopic.php?f=4&amp;t=53129" target="_blank">ran a survey</a> on this to see what people were using already. Git tends to get a lot of fans talking about it, but I&#8217;m also very aware that evangelists aren&#8217;t usually the best people to listen to. By asking people what they used practically, rather than which one they thought they might like to use, I hoped to tease out usage numbers. Of course, popularity is no guaranteed measure of quality, but it&#8217;s a reasonable indication of how each system might be received by our community. As it turned out, and not unexpectedly, most people had only seriously used one of the DVCSs and liked the one they were using, but had no real view on any of the others.</p>
<p>The sample wasn&#8217;t huge &#8211; only 64 people voted (but pleasingly a power of 2!) &#8211; and the numbers were as follows: Git 52% Mercurial 41% (Bazaar 8%). This nicely translates objectively into a score!</p>
<p><strong>Conclusion</strong></p>
<p>Well, this is annoying. My 10 criteria actually resulted in equal scores &#8211; trust me, I didn&#8217;t fake this; I thought very hard about these scores because I found myself being indecisive between the two systems because they both had positive and negative aspects, and I figured the only way to resolve the overall result was to try to score them and let math solve the problem. So much for that idea &#8211; it seems when I set them out numerically they are as balanced as they were more abstractly in my head.</p>
<p>So in the end, it comes down to the relative importance of these 10 items. I tried to pick 10 things that were of roughly equal importance to avoid skewing anything, but if really pushed I&#8217;d have to say that consistency across platforms and confidence in the reliability and error reporting has to be more important to me personally than most of the other factors. The one exception is the storage size &#8211; I <em>want</em> people to clone the source repository so they are encouraged to get involved in development, and I&#8217;m aware that the larger it is, the more that&#8217;s a disincentive. 200MB is pushing it a bit, and it&#8217;ll only get larger &#8211; and according to Mercurial&#8217;s specs that&#8217;s already compressed. In comparison, right now according to my measurements someone grabbing our Subversion repository has to transfer about 48MB of data (compressed) per branch over the network, so Git&#8217;s 116Mb (again, compressed) is looking very attractive compared to Mercurial&#8217;s heft.</p>
<p>I think that if I can find a way to reduce the size of the Mercurial repository to around 100MB, perhaps by stripping the <em>old</em> trunk history somehow (stripping old branches doesn&#8217;t appear to have made a great deal of difference), but while still keeping branches after this point, I&#8217;d go with Mercurial just because on balance it behaved more consistently for me. If I can&#8217;t, I&#8217;m still annoyingly on the fence becuase 200Mb feels too big, but I can&#8217;t afford to trash all my history or branches. There is lots of talk in the Mercurial wiki about shallow clones and potential history trimming extensions, but nothing seems solid right now. Anyone have any suggestions?</p>
]]></content:encoded>
			<wfw:commentRss>http://www.stevestreeting.com/2009/11/06/dvcs-score-card/feed/</wfw:commentRss>
		<slash:comments>22</slash:comments>
		</item>
		<item>
		<title>Adventures in conversionland</title>
		<link>http://www.stevestreeting.com/2009/10/25/adventures-in-conversionland/</link>
		<comments>http://www.stevestreeting.com/2009/10/25/adventures-in-conversionland/#comments</comments>
		<pubDate>Sun, 25 Oct 2009 20:57:04 +0000</pubDate>
		<dc:creator>Steve</dc:creator>
				<category><![CDATA[Development]]></category>
		<category><![CDATA[OGRE]]></category>
		<category><![CDATA[conversion]]></category>
		<category><![CDATA[DVCS]]></category>
		<category><![CDATA[Git]]></category>
		<category><![CDATA[Mercurial]]></category>
		<category><![CDATA[ogre]]></category>
		<category><![CDATA[subversion]]></category>
		<category><![CDATA[svn]]></category>

		<guid isPermaLink="false">http://www.stevestreeting.com/?p=2310</guid>
		<description><![CDATA[As  you know I&#8217;ve been reviewing DVCSs lately. I&#8217;m taking my time doing real use cases on them, and deliberately not doing the sort of feet-first leap into whatever looks best / most popular on the surface because I don&#8217;t particularly want to discover unexpected problems down the track. It&#8217;s consuming a lot more time [...]]]></description>
			<content:encoded><![CDATA[<p>As  you know I&#8217;ve been reviewing DVCSs lately. I&#8217;m taking my time doing real use cases on them, and deliberately not doing the sort of feet-first leap into whatever looks best / most popular on the surface because I don&#8217;t particularly want to discover unexpected problems down the track. It&#8217;s consuming a lot more time than I expected &#8211; I&#8217;m writing up my findings and may publish the entire results later on if I can find the time to clean them up and format them better, but for the moment I thought I&#8217;d share some experiences with the conversion process of a relatively large, long-lived, multi-branch repository (OGRE) from Subversion to Git and Mercurial, because that&#8217;s what I&#8217;ve been wrestling with in the last few days. I discovered a bunch of additional issues during this process that did not occur when starting from scratch or doing conversions from more trivial repositories, so I thought it might help others to talk about it.</p>
<p><strong>Source Subversion repositiory specifications</strong></p>
<p>Revisions: 9215 (as of today)<br />
Branches:  9 permanent, 22 temporary / experimental<br />
Size: 375 MB</p>
<p>Also of note is that the source repository is still at Subversion 1.3 &#8211; this is because Sourceforge was stuck on this version for a long time and we haven&#8217;t upgraded the repository since they started supporting newer versions. We never bothered because it requires locking out the repository while you download the whole thing to a local machine, upgrade it and re-upload it, which is a hassle, especially when you have things to do. In practice the server-side version hasn&#8217;t been a major issue since you can still use newer clients with it and svnmerge operates regardless.</p>
<p><strong>General Approach</strong></p>
<p>I rsync the OGRE repository down to a local Linux server several times a week, so that was the source of all my conversions, eliminating most of the network time. I tried to convert the repositories using Windows clients in the first instance, because that was easier to use the latest versions of the tools (my Linux Server is on Ubuntu 8.04 LTS and even with hardy-backports available it&#8217;s not as up to date &#8211; and for simplicity because this is an important server I stick to the official versions). There is a 1Gb network connection between the machines so it could be pretty speedy.</p>
<p>The principle is that I want to preserve all history, all branches, and all tags. In practice I may actually prune off some branches later on, so that the clone process is quicker, but the base principle is that it should be a lossless conversion in the first instance. Definitely no top-skimming of the trunk like some conversion articles advocate &#8211; we have stable branches that must be maintained and regularly have work that we want to keep in experimental branches. In particular, post conversion it must be possible to continue committing to and merging from stable branches.</p>
<p><strong>Git </strong><strong>Conversion Experience </strong></p>
<p>I&#8217;d previously converted some other, small and fairly simple Subversion repositories using git-svn (less than 500 revisions, and 2-3 branches) and it worked fine. However, when trying it against the considerably more complex OGRE repository I hit problems very quickly. On Windows, using msysGit 1.6.4 the process failed after 1900 revisions, just after doing the automatic repository tidy (git gc). The error message was simply &#8216;fatal error running git-svn&#8217;, even though it had been running exactly that command for the last 1900 revisions. Thinking there might be an msysGit issue here, I switched to the Linux server (git 1.5.4) and tried the same thing. This time it fell over at revision 176 with absolutely no error message. In both cases the repository left behind was corrupt so I could not resume the process.</p>
<p>The other thing I noticed was how long the process took on Windows. 1900 revisions took 5 hours (!) and thus I wasn&#8217;t in a hurry to retry the process there. On Linux the process was much faster, as far as it got. It&#8217;s worth noting that this is not caused by running across 2 machines &#8211; not only do I have a very adequate 1Gb link, Mercurial managed significantly faster conversions using the same topology. msysGit&#8217;s git-svn conversion is simply incredibly slow.</p>
<p>At this point I decided to try upgrading the Subversion repository, just in case git-svn hadn&#8217;t been tested with older repository versions. My Linux server had svn 1.5 on it, so I upgraded the OGRE repository to that locally and re-ran the git-svn process on the Linux machine (as I say, I wasn&#8217;t keen on repeating the glacially slow msysGit conversion). Sure enough, this time all 9200-odd revisions converted fine, in only about 1 hour 40 minutes, or about 15 times faster than doing it on Windows.</p>
<p>So, I may have had a few problems, and being forced to upgrade the repository before converting was a bit of a pain, but at least it worked and was fast (on Linux anyway). After that, I started cloning the repository both on Linux and Windows and tried performing some standard operations.</p>
<p>The first thing that surprised me was that when cloning the converted repository, I could only see the &#8216;master&#8217; branch on the remote machine. It&#8217;s common practice for Git not to create any local branches other than master on clone, but usually you can do &#8216;git branch -a&#8217; to see all the remote branches that are available, which show up as something like &#8216;origin/v1-6&#8242; &#8211; you can then check them out to local branches. However, no branches other than &#8216;origin/master&#8217; showed up, even though I knew they&#8217;d been converted. It turns out that git-svn converts all branches except master into <strong>remote</strong> branches in the converted repository, referencing the original Subversion URL &#8211; so very much like having cloned from another Git repository. That sort of makes sense, but in the context of a full conversion to a repository that is destined to become the upstream master, isn&#8217;t that useful. In practice what you need to do is after the git-svn conversion is complete, git checkout each of the branches that you care about in your converted repository, thus creating local branches in that repository which subsequent cloners will be able to checkout themselves.</p>
<p>So, once I&#8217;d figured this out I started to check out different branches to test if it had worked. At first it seemed to, when checking out the first branch (switching from master to v1-6 in a local clone from the conversion). When I came to try to switch back to master however, Git complained that I had modified files in my working directory. WTF? I&#8217;d only just checked out the clean copy of the v1-6 branch. But sure enough, git status told me I had 5 modified files. Diffing them showed no changes, and &#8220;git reset &#8211;hard&#8221; returned with no error, but git status still showed these files as modified. Bizarre. A git checkout -f still let me switch, but again after completion a set of other files showed up as modified. Switching back and forth (with -f) a few times revealed that the list of modified files after checkout was different each time. Again worried that this was a Windows thing, I tried checking out on my Linux machine instead (so at that stage the entire process, conversion to checkout, was done on Linux). But no, the same problem occurred &#8211; a random selection of 5-7 modified files on clean checkout.</p>
<p>This has raised some serious concerns about using Git for me. Firstly the flaky conversion which requires a bunch of extra steps just to get it to work at all, then the post-conversion bizarre behaviour of thinking files are modified when they&#8217;re not. I had none of these problems with smaller repositories, created from scratch or converted, which up until now I&#8217;d been using for testing (and Git had been winning me over in fact since it had been working well). But the bottom line is that this process needs to work reliably for the OGRE repository. If it doesn&#8217;t, it&#8217;s pretty much untenable.</p>
<p><strong>Mercurial Conversion Experience</strong></p>
<p>I started off with the in-built &#8216;hg convert&#8217; process. It all went smoothly and took about 8 hours, and the resulting repository was mostly fine. However, the default behaviour is to process the revisions in an order which &#8220;produces the fewest jumps between branches in the commit log&#8221;. In practice, I found that this meant the revision log when reviewing multiple branches was badly jumbled and difficult to use; the use of the &#8216;&#8211;datesort&#8217; option resolved this but increased the conversion time to just under 10 hours (still faster than msysGit but a lot slower than git on Linux).</p>
<p>The guys from BitBucket, who I&#8217;d talked to to see if they would offer free unlimited hosting for OGRE since we wouldn&#8217;t fit in the default 150MB limit (result was that they were super-friendly and offered not only that but lots of advice), suggested that I try hgsubversion instead. I was initially put off by their website suggesting it wasn&#8217;t fit for production use (they&#8217;ve removed this statement now), but BitBucket told me that was a little out of date, and in fact the Python project is using it for their conversion, which is obviously of major size. So, I gave it a shot and got some good help from the hgsubversion guys, and the results were great &#8211; 1hour 40 minutes from the Windows end (coincidentally the same speed Git managed on the local Linux machine), and the log view was properly ordered right off the bat.</p>
<p>The one remaining issue I had (and this is true of git-svn too) is that all of the branches are open-ended on conversion &#8211; that is, no record is made of merges that have been done between branches. That means you would have problems continuing a branch and then merging it, because Mercurial would think it has to merge everything from the point the branch was taken. Neither svnmerge or svn:merge properties are taken into account.</p>
<p>One way to resolve this is to manually create a merge point to close off the branches. The easiest way to do this is:</p>
<ul>
<li>Grab the default tip<span style="text-decoration: none;"> </span></li>
<li><span style="text-decoration: none;"><span style="font-weight: normal;">Open 	a command line and define a temporary environment variable 	“HGMERGE=internal:local”. This means that you want to keep the 	local files and throw away the other source when doing a merge, 	which is important for our dummy merge</span></span></li>
<li>hg 	merge &lt;source_branch&gt; -y<span style="text-decoration: none;"><span style="font-weight: normal;"><br />
</span></span></li>
<li>commit &#8211; only the .hgtags file should be modified, the rest of the commit is merely metadata alteration to close off the source_branch</li>
</ul>
<p>Once you&#8217;ve done that, your branch is joined back to the trunk and you can carry on as before, any new commits to that branch will merge across cleanly. The only downside of this is that the merge is strictly at the wrong point &#8211; if you view the history in the trunk it won&#8217;t be technically accurate and you&#8217;ll need to use your commit messages as the real guide to the actual merges before the conversion.</p>
<p>A better way to do this would be to record the merges during the conversion, that is for merge commits in Subversion to have 2 parents. So far, none of the conversion tools read svnmerge or svn:merge metadata to implement this, but the standard &#8216;hg convert&#8217; has an option called &#8216;&#8211;splicemap&#8217; where you can specify merge points to be applied during the conversion. Unfortunately I&#8217;ve tried to use this twice so far, and both times it hasn&#8217;t worked (just silently done nothing). The documentation for &#8211;splicemap is not great so it could be I got the URLs wrong. But anyhow, following 2 failed attempts (20 hours! because this was the standard hg convert with &#8211;datesort) I decided I&#8217;d try to get a similar bit of functionality working in hgsubversion instead, since that&#8217;s much faster (1hr 40m a pop). Right now I&#8217;m hacking away on it to try to make this work, so far it&#8217;s not but I&#8217;ll let you know if I eventually succeed. One of the benefits of Mercurial is that it&#8217;s all in Python so it&#8217;s very easy to modify, compared to Git which runs all kinds of random scripts and executables, including  sh and perl so it&#8217;s much more tangled to dig into.</p>
<p><strong>Conclusions, so far<br />
</strong></p>
<p>I <a href="http://www.stevestreeting.com/2009/08/04/playing-with-mercurial/">started my DVCS evaluation</a> very pro-Mercurial and very anti-Git. While working through <a href="http://www.stevestreeting.com/2009/08/06/getting-more-structured-with-my-dvcs-tests/">my detailed use cases</a>, a process which I&#8217;ve not quite completed yet, Git has grown on me a great deal, and I discovered a few things about Mercurial which I found a bit limiting at first, but which are mitigated via extensions &#8211; Rebase, Queues and Transplant particularly. My recent experience with more complicated, full-scale and imported repositories has once again gone in Mercurial&#8217;s favour though, and I saw a nastier side of Git &#8211; when it goes wrong, it&#8217;s a lot more difficult to figure out why. In contrast when I&#8217;ve had my Mercurial conversion crash &#8211; and I stress this only happened due to my own screw up, once because it ran overnight when my rsync kicked in and changed the repository under its feet, and a few times when I&#8217;ve been experimenting with hacking the Python to get the merges done &#8211; the reason has always been clear; a nice Python trace, and the repository was always intact anyhow &#8211; in the case of the core hg convert the conversion even restarted from where it left off once I&#8217;d fixed it.</p>
<p>If I were to graph my relative opinion of the two over the period I&#8217;ve been doing this so far, it would look something like this:</p>
<p style="text-align: left;"><img class="size-full wp-image-2312 aligncenter" title="gitmercurialopinion" src="http://www.stevestreeting.com/wp-content/uploads/2009/10/gitmercurialopinion.gif" alt="gitmercurialopinion" width="500" height="121" /></p>
<p style="text-align: left;">Git totally came up from behind and I was really starting to dig it, until it started freaking out on me with the conversion and I started to try to diagnose why and found it mostly unhelpful. Again I stress I&#8217;m not done with my tests yet, but I&#8217;m perhaps 75% of the way through now and the conversion problems I&#8217;ve had with Git in the last few days don&#8217;t look good. Bazaar, I&#8217;m afraid, is no longer likely to be part of the evaluation &#8211; it takes a long time to do these evaluations properly rather than just trivially, and <a href="http://www.ogre3d.org/forums/viewtopic.php?f=4&amp;t=53129&amp;start=25&amp;view=viewpoll" target="_blank">our survey</a> has indicated that it is the least commonly used among our community by a <em>very </em>large margin, so I&#8217;m focussing on the ones more users are likely to already be comfortable with.</p>
<p style="text-align: left;">The evaluation process continues&#8230;</p>
<p><!-- 		@page { margin: 2cm } 		P { margin-bottom: 0.21cm } --></p>
]]></content:encoded>
			<wfw:commentRss>http://www.stevestreeting.com/2009/10/25/adventures-in-conversionland/feed/</wfw:commentRss>
		<slash:comments>17</slash:comments>
		</item>
		<item>
		<title>Early-stage Git/Mercurial/Bazaar evaluation thoughts</title>
		<link>http://www.stevestreeting.com/2009/09/28/early-stage-gitmercurialbazaar-evaluation-thoughts/</link>
		<comments>http://www.stevestreeting.com/2009/09/28/early-stage-gitmercurialbazaar-evaluation-thoughts/#comments</comments>
		<pubDate>Mon, 28 Sep 2009 11:27:20 +0000</pubDate>
		<dc:creator>Steve</dc:creator>
				<category><![CDATA[Development]]></category>
		<category><![CDATA[Tech]]></category>
		<category><![CDATA[bazaar]]></category>
		<category><![CDATA[DVCS]]></category>
		<category><![CDATA[Git]]></category>
		<category><![CDATA[Mercurial]]></category>

		<guid isPermaLink="false">http://www.stevestreeting.com/?p=2257</guid>
		<description><![CDATA[A few weeks ago I decided to start seriously investigating switching to a DVCS. I&#8217;m currently up to my eyes in work and haven&#8217;t really had time to progress that in the last few weeks; however some absolutely abhorrent performance / reliability problems with Sourceforge&#8217;s Subversion server made a large merge process so costly to [...]]]></description>
			<content:encoded><![CDATA[<p>A few weeks ago I decided to start seriously investigating switching to a DVCS. I&#8217;m currently up to my eyes in work and haven&#8217;t really had time to progress that in the last few weeks; however some absolutely abhorrent performance / reliability problems with Sourceforge&#8217;s Subversion server made a large merge process so costly to me (in the end I had to commit in small chunks, breaking transactional consistency, and it needed so much babysitting because of the speed / reliability it took me 4 bloody hours just to commit!!) that it bumped it up my agenda a bit. I don&#8217;t have to do merges / commits of that size very often &#8211; in this case the problem was wholesale license header changes for our MIT switch &#8211;  but still, it&#8217;s totally unacceptable to have to deal with that. I raised a support request with Sourceforge, but I&#8217;ve seen other reports of bad SVN performance from several weeks ago from others, so I&#8217;m not holding my breath. It&#8217;s time to start considering alternative hosting I think.</p>
<p>I&#8217;m not done with my evaluation yet, because I just don&#8217;t have the dedicated time I really want to spend on this right now. But, here&#8217;s my early-stage results.</p>
<p><strong>Git</strong></p>
<p>I&#8217;ve discussed before that I don&#8217;t like the where Git has come from. It&#8217;s overly complicated, Windows support was clearly not a priority, and it switched existing VCS terminology around just for the sake of it a lot of the time. It practically shouts &#8220;I&#8217;m different, live with it!&#8221; at you, which is frankly a typical elitist geek attitude and not one I particularly respect. This attitude permeates the documentation, reinforced by the absolute insistence of most tutorials that you need to understand Git&#8217;s underlying data model before you start using it. Er, right &#8211; sorry, but when normal people want to learn how to use a new tool, we just want to know how to use it, not how it&#8217;s built. If understanding how it&#8217;s built is a prerequisite to using it, then I&#8217;m sorry, it fails miserably at being user friendly.</p>
<p>Nevertheless, it&#8217;s fast, it&#8217;s efficient in storage, it&#8217;s the most popular &amp; fashionable DVCS (probably due to GitHub) and that has weight. Of particular interest to me is that TortoiseGit has come along in leaps and bounds, and is really quite pleasant to use. Of course, the reason it&#8217;s pleasant is because it hides the majority of the nonsensical changes that Git decided to make to existing VCS terminology; for example &#8216;Revert&#8217; in TortoiseGit does what you expect (undoes your working copy changes), rather than needing to use &#8216;git reset &#8211;hard&#8217;, which is only intuitive to those who live on Mars (git revert, in contrast, records a new commit to undo a previous commit &#8211; why the hell do you need a special command for that??). Thus, it&#8217;s an odd situation &#8211; using TortoiseGit is pleasant, but only because it ushers the underlying git behind a curtain and gives you what most people really wanted from it in the first place. The downside is that using TortoiseGit really doesn&#8217;t teach you how to use the command line very well, like most other VCS tools do. In fact, it may well mislead you into thinking Git is friendlier than it actually is. For example, it saves you from the ridiculous need to remember the &#8220;-a&#8221; argument to &#8220;git commit&#8221; &#8211; without which what you actually get in your commit is the state of the file when you did &#8220;git add&#8221;, not the version in your working copy. If that makes sense to anyone, raise your hand. Thought not.</p>
<p>Hosting &amp; collaboration wise, <a href="http://www.github.com" target="_blank">GitHub</a> seems very good.</p>
<p><strong>Mercurial</strong></p>
<p>Mercurial on the command line is nice. It behaves the same way centralised VCS&#8217;s do, except in the cases where it needs to be different. This is pragmatic design &#8211; not being different just to make a point, but being different where it needs to be. It doesn&#8217;t break old concepts and does what you expect it to, and contrary to what some people think, that&#8217;s a very valuable feature.</p>
<p>It&#8217;s not all roses though. TortoiseHg is clunkier than TortoiseGit, despite being based on a more intuitive core tool. The UI just feels a bit wrong (like putting action buttons on the toolbar &#8211; who does that?), and I&#8217;ve sworn at it for being unintuitive more than once. The other problem is that the Mac GUI tools are not really that great either &#8211; MacMercurial only allowed me to do a subset of the operations I needed to do, and Murky just crashed when I tried it. GitX in comparison works quite well on the Mac.</p>
<p>So despite a more intuitive command line and core concepts, and a more pragmatic approach generally to DVCS for &#8216;regular&#8217; people, when it comes to GUIs Mercurial lags a bit now. This was unexpected to me since it is Git that has traditionally been poor on the GUI front. There are also a few other minor issues like branches being totally permanent and needing to be globally uniquely named, which can make local experiments more cumbersome.</p>
<p>Hosting wise, <a href="http://www.bitbucket.org" target="_blank">BitBucket</a> seems quite competent, if a little less polished than GitHub.</p>
<p><strong>Bazaar</strong></p>
<p>I&#8217;ve only just started experimenting with Bazaar, and so far I&#8217;m quite impressed. It has the pragmatic approach of Mercurial, but also has a built-in GUI which is really quite nice to use and leads you through the initial setup and configuration. There&#8217;s also TortoiseBzr which feels somewhere in between TortoiseHg and TortoiseGit. I haven&#8217;t tried it on the Mac yet. Performance was always the issue listed as the major downside of Bazaar, <a href="http://www.faulhammer.org/archiv-mainmenu-31/35-gentoo/304-gitbazaar-historical-performance-comparison-revisited" target="_blank">but this has improved since 2.0</a> and while it&#8217;s not as fast as Git, it seems to be fast enough.</p>
<p>The main downside for Bazaar is adoption. It trails both Git and Mercurial in terms of the number of people using it, and therefore adopting it for a public project would have the disadvantage of making people use a tool they&#8217;re less likely to already be familiar with. Also for hosting, <a href="http://www.launchpad.net" target="_blank">Launchpad</a> is quite new; it looks quite good, and has more features than GitHub, but it doesn&#8217;t have the option to host private projects (not an issue for Ogre of course) or a graduated commercial plan &#8211; you can self-host of course but that&#8217;s not as easy.</p>
<p><strong>Conclusions so far</strong></p>
<p>The sad fact is that none of the 3 are an instant win for me; they all have positive and negative aspects. Summary so far:</p>
<table border="1" cellspacing="0" cellpadding="5" align="center">
<tbody>
<tr>
<td><strong>Tool</strong></td>
<td><strong>Pros</strong></td>
<td><strong>Cons</strong></td>
</tr>
<tr>
<td>Git</td>
<td>Fastest &amp; most efficient<br />
GUIs actually good<br />
Popular</td>
<td>Command line overcomplicated &amp; unintuitive<br />
Mistakes easier to make</td>
</tr>
<tr>
<td>Mercurial</td>
<td>Intuitive<br />
Fairly popular</td>
<td>GUIs a bit rough in places</td>
</tr>
<tr>
<td>Bazaar</td>
<td>Very intuitive<br />
Built-in GUI good<br />
TortoiseBzr also good</td>
<td>Not very popular<br />
Statistically the slowest<br />
Launchpad is quite new</td>
</tr>
</tbody>
</table>
<p>So, I&#8217;m basically in a no-win scenario. If I pick Git, it&#8217;ll work fine via the GUIs but it&#8217;s too easy to screw things up when using the command line, and I&#8217;m bound to get annoyed at the needless obscurity from time to time. But, lots of people will be happy to use it. If I pick Mercurial, I&#8217;ll be happier with the overall core concepts &amp; command line, but the rough edges on the GUIs are going to annoy me day to day. But, quite a few people will be happy with it all the same. If I pick Bazaar, I&#8217;ll be happy with both the core concepts and the GUIs, but being the least fashionable option almost no-one in the community will be happy that I picked it over the other two, and lots will bitch about having to use another tool.</p>
<p>I&#8217;m reluctantly acknowledging that the least of the evils appears to be Git right now, even though I personally hate its underlying interface. Somehow it feels wrong to only like using it when it&#8217;s hidden beneath a GUI &#8211; I&#8217;ve been a regular user of the command line for CVS and SVN for the best part of a decade, and I like being happy with both modes. I can imagine tolerating Git&#8217;s command line, but never liking it just because of the unnecessary idiosyncracies (like commit -a).</p>
<p>I still have lots more detailed tests to do anyway, which will have to wait a month or so until I have more time.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.stevestreeting.com/2009/09/28/early-stage-gitmercurialbazaar-evaluation-thoughts/feed/</wfw:commentRss>
		<slash:comments>65</slash:comments>
		</item>
		<item>
		<title>Getting more structured with my DVCS tests</title>
		<link>http://www.stevestreeting.com/2009/08/06/getting-more-structured-with-my-dvcs-tests/</link>
		<comments>http://www.stevestreeting.com/2009/08/06/getting-more-structured-with-my-dvcs-tests/#comments</comments>
		<pubDate>Thu, 06 Aug 2009 12:18:10 +0000</pubDate>
		<dc:creator>Steve</dc:creator>
				<category><![CDATA[Development]]></category>
		<category><![CDATA[Open Source]]></category>
		<category><![CDATA[DVCS]]></category>
		<category><![CDATA[Git]]></category>
		<category><![CDATA[Mercurial]]></category>

		<guid isPermaLink="false">http://www.stevestreeting.com/?p=2163</guid>
		<description><![CDATA[Ok, so I&#8217;ve posted my initial feelings about tinkering with Mercurial and Git, and that seems to have generated some interest. It&#8217;s time to get a bit more formal about how I&#8217;m going to evaluate them against each other, to decide which one I like to use most in real, practical scenarios. So, I decided [...]]]></description>
			<content:encoded><![CDATA[<p>Ok, so I&#8217;ve posted my <a href="http://www.stevestreeting.com/2009/08/04/playing-with-mercurial/" target="_blank">initial feelings</a> about tinkering with Mercurial and Git, and that seems to have generated some interest. It&#8217;s time to get a bit more formal about how I&#8217;m going to evaluate them against each other, to decide which one I like to use most in real, practical scenarios. So, I decided to come up with a list of use cases for the things that I typically have to deal with when managing the repositories for a software project (open source and otherwise), so that I can methodically test them out and see how I feel about each system. I&#8217;ve tried to deliberately include use cases for things that you can&#8217;treally do on a centralised system, but that I&#8217;d want to make use of, as well as the usual nonsense that happens day-to-day on a typical project <img src='http://www.stevestreeting.com/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /> </p>
<p>I&#8217;ve presented my work-in-progress list below, feel free to suggest more use cases I can test. I really want to see what these things are like in practice in the kinds of situations I encounter in real projects, without <em>actually risking</em> a real project in the process! Like a backup / restore strategy, it&#8217;s no good doing it for the first time when the sh*t has already hit the fan.</p>
<p>Oh, and for fun, allegedly <a href="http://importantshock.wordpress.com/2008/08/07/git-vs-mercurial/" target="_blank">Git is MacGyver and Mercurial is James Bond</a> . <img src='http://www.stevestreeting.com/wp-includes/images/smilies/icon_biggrin.gif' alt=':D' class='wp-smiley' /> </p>
<hr /><em>This list will be periodically updated as I think of new things, and as other things are suggested by commenters</em>.</p>
<p>Due to the nature of a DVCS, all these use cases must be tested both in isolation, and  after pushing those changes to another potentially &#8216;superset&#8217; repository.</p>
<ol>
<li>General
<ol>
<li>Commit a few changes to local repository &#8216;A&#8217; but don&#8217;t push to central yet. Push a number of different changes to the central repository from a different repository &#8216;B&#8217;. Then, pull &#8216;B&#8217;s changes from the central repos to local repository &#8216;A&#8217;  to bring it up to date, again without pushing A&#8217;s outstanding changes yet. This is equivalent to doing an &#8216;svn update&#8217; while you have local uncommitted changes in Subversion, but while using the local commit features of the DVCS. How does this work in practice? [Suggested by Arseny Kapoulkine]</li>
</ol>
</li>
<li>Branching
<ol>
<li>Create a new public, official branch (stable branch)</li>
<li> Create a new long-term feature branch which is intended for public consumption / collaboration</li>
<li> Create lots of short-term development branches (or equivalent structures) intended for local consumption only
<ol>
<li>What are the size overheads? (Git claims superiority here)</li>
<li> Does this excessively clutter the public repository when pushed?</li>
<li> Is there a better way of handling multiple local changesets which you may or may not decide to push individually, such as testing many patches (Mercurial queues seem very interesting, Git equivalent?)</li>
<li>. Rename a branch? (optional)</li>
</ol>
</li>
</ol>
</li>
<li>Merging
<ol>
<li>Merge changes unidirectionally from one branch to another, without having to manually pick revisions. Make more changes in the source branch and repeat.</li>
<li>Bidirectional merge &#8211; a feature branch which is not yet ready to be merged into the trunk wants to resynchronise from the trunk and continue branched development. Merge of this branch into the trunk must be tested later after further changes</li>
</ol>
</li>
<li>Tagging
<ol>
<li>Create a tag against a specific branch; probably at the HEAD but look for the option to specify a revision</li>
<li>Correct / modify / move a tag following a mistake or last-minute revision (pre-release) without having to make duplicate commits or other such spurious activity</li>
</ol>
</li>
<li>Firefighting
<ol>
<li>Screw-up: developer commits change to trunk instead of stable branch. Merge / move it to the stable instead &#8211; change can be left in the trunk or can be removed for re-merging, so long as the procedure is clear.</li>
<li>Screw-up: developer commits change to stable branch that is interface-breaking, must be removed and moved to the trunk. Must be removed from the stable branch and moved.</li>
<li>Screw-up: Revert a single change from the repository, that is not at the HEAD</li>
</ol>
</li>
<li> External patch submission tests:
<ol>
<li>Patch file from same branch, no conflicts</li>
<li> Patch file from same branch, with conflicts</li>
<li>Patch file generated on a different branch to the one we want to apply it to (include conflicts)</li>
<li>Pull from third-party repository, entire branch</li>
<li>Pull from third-party respository, specific changes</li>
<li>Patch file generated from non-repository source copy</li>
</ol>
</li>
<li> Backup multiple work-in-progress changes on a local machine that are not ready for public consumption; approaches:
<ol>
<li>Store a patch per local branch (this is how it&#8217;s done with SVN, but too much hassle if you use lightweight local branching, DVCSs can do better)</li>
<li> Push to a backup repository on another machine across existing protocols &#8211; ssh, https, Samba share (Git can&#8217;t do the latter?)</li>
<li> Push to a backup respository on a USB stick (Git can&#8217;t do this?)</li>
</ol>
</li>
<li>Binary files
<ol>
<li>Revise a binary file over a few versions, test storage efficiency</li>
<li>Binary file conflict resolution</li>
</ol>
</li>
<li>Conversion from Subversion
<ol>
<li>Import retaining history</li>
<li>Import multiple branches</li>
<li>Import tags</li>
</ol>
</li>
<li>Integration
<ol>
<li>Mailing list / RSS notifications of commits on official repository</li>
<li>Bugtrackers</li>
<li>CIA.vc et al?</li>
<li>Good free &amp; open source GUI clients for all platforms</li>
<li>Line ending conversions between platforms</li>
</ol>
</li>
</ol>
]]></content:encoded>
			<wfw:commentRss>http://www.stevestreeting.com/2009/08/06/getting-more-structured-with-my-dvcs-tests/feed/</wfw:commentRss>
		<slash:comments>16</slash:comments>
		</item>
		<item>
		<title>Playing with Mercurial</title>
		<link>http://www.stevestreeting.com/2009/08/04/playing-with-mercurial/</link>
		<comments>http://www.stevestreeting.com/2009/08/04/playing-with-mercurial/#comments</comments>
		<pubDate>Tue, 04 Aug 2009 22:04:04 +0000</pubDate>
		<dc:creator>Steve</dc:creator>
				<category><![CDATA[Development]]></category>
		<category><![CDATA[Open Source]]></category>
		<category><![CDATA[DVCS]]></category>
		<category><![CDATA[Git]]></category>
		<category><![CDATA[Mercurial]]></category>
		<category><![CDATA[source control]]></category>

		<guid isPermaLink="false">http://www.stevestreeting.com/?p=2157</guid>
		<description><![CDATA[I&#8217;ve been interested in DVCS for a while; having done my fair share of branch management, something which makes that process easier and more transparent is definitely very attractive. I particularly like the way a DVCS makes it easier for people to collaborate in pockets of their own, away from the centralised environment, and track [...]]]></description>
			<content:encoded><![CDATA[<p>I&#8217;ve been interested in DVCS for a while; having done my fair share of branch management, something which makes that process easier and more transparent is definitely very attractive. I particularly like the way a DVCS makes it easier for people to collaborate in pockets of their own, away from the centralised environment, and track other repositories and keep their local mods up to date more easily &#8211; public-branch-on-demand if you will. However, I&#8217;m yet to be convinced by Git for everyday use. As noted, I love the idea, but Git comes across as &#8211; and this is an ironic thing for me to say &#8211; excessively geeky. At one time I might have believed there was no such thing as a plethora of geekery, but I like to think I&#8217;m a more rounded individual now <img src='http://www.stevestreeting.com/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /> </p>
<p>Don&#8217;t get me wrong, I&#8217;m sure Git is technically excellent. But a number of things about it remind me of the somewhat stubborn purisms of  &#8216;old Linux&#8217;, such as:</p>
<ul>
<li>The documentation is hugely daunting. Whenever anyone tried to convince me why Git is amazing, they point me at documentation that just makes me not want to touch it for anything important. The impression I get is akin to some Linux forums: &#8211; this thing is powerful, but it gives you plenty of rope to if not hang yourself, then to tie yourself in knots if you don&#8217;t know what you&#8217;re doing.</li>
<li>It <em>requires </em>a Unix back end, to the extent that you have to run it under Cygwin on Windows, and its rigid filesystem requirements mean it won&#8217;t work on FAT or Windows network drives. I get the impression there&#8217;s something rather aloof about the fact that the core team don&#8217;t consider it an issue that Git won&#8217;t run on native Windows environments. There are external projects working on that, but the fact that it&#8217;s not core is a concern, since I prefer all my 3 platforms to be supported equally.</li>
<li>The UIs still don&#8217;t seem very user-friendly, and most responses I see to the question of why that is boil down to &#8220;Git is too powerful to be captured in a GUI&#8221;. Sorry, but I don&#8217;t buy that &#8211; no system is too complex to be captured in a user-friendly tool, it just takes the will to do it, and like &#8216;old Linux&#8217;, there seems to be little will to make Git more approachable.</li>
</ul>
<p>So, I&#8217;ve never had great vibes from Git, despite it&#8217;s doubtless technical merits. So, I decided to check out <a href="http://mercurial.selenic.com/wiki/" target="_blank">Mercurial</a> instead &#8211; from what I read, Git is the fashionable DVCS that all the cool kids want to be seen using, but when it comes down to it Mercurial does exactly the same thing &#8211; except that it has native support for all platforms out of the box and TortoiseHg is looking pretty mature. I also read that it handles binary files better than Git too, since it does binary diffs everywhere. The documentation seemed much more approachable too, so I figured I&#8217;d have a play.</p>
<p>My first impressions are <em>incredibly</em> positive. The most impressive thing of all is that I imported a (relatively small- about 100 revisions) Subversion repository, with all the history intact, about 5 minutes after installing it, and was bouncing that across Linux and Windows immediately afterwards (haven&#8217;t tried OS X yet). TortoiseHg is instantly familiar, and despite the fact that the concepts are the same as Git, the presence of <em>some</em> familiarity, together with some distinctly less intimidating documentation, has me feeling far happier than the times I&#8217;ve dipped into the Git docs. Mercurial&#8217;s approachability is a positive contrast to Git&#8217;s Unix-purist, RTFM style I think. I know which I prefer so far.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.stevestreeting.com/2009/08/04/playing-with-mercurial/feed/</wfw:commentRss>
		<slash:comments>31</slash:comments>
		</item>
	</channel>
</rss>

