Thoughts on the Current State of Source Control
May 17th, 2009The world of version control (if there is such a thing), is currently in a state of flux. The old guard of centralised source control management systems are under attack from the young and up and coming distributed version control systems.
I was first brought into this world when I was introduced to Subversion fairly early on in my programming career. I certainly took my time to get familiar with the system but as far as I was concerned, it made perfect sense and it worked.
Fast forward a few years and I was thoroughly frustrated by “SVN”, not the workflow, but the fact that it didn’t seem to handle anything even mildly advanced. Branching was a joke and merging was hugely painful.
It was around that time when I was introduced to Git. Git was an entirely different way of thinking about version control. As opposed to having a centralised repository, in which you check in changes. The repository is on your system. You then “push” and “pull” to other repositories located on your colleagues machines. There is no enforced “central” repository, but you build and release from whichever branch you feel is the most appropriate on whatever machine.
Here is problem number one. I fundamentally disagree with that being a good way to release software. If you are a company you are just inviting confusion. It is much clearer to have a centralised repository that you are working towards. Sure there are services like GitHub, but as far as I can see that is not using the software how it was designed to be used, whether you consider that a problem is up to you.
However, it is not that simple. Git actually worked, and worked well. True branching and merging changed the way I managed my code and on top of that it is blazingly fast. I also found huge benefits in having a local repository. It became cheap to browse my entire repository history and “checkout” older versions. On top of all this, Git introduced some great features such as “git stash”, a system allowing you to temporarily store changes without properly checking them into the repository. So what I needed was a system which is centralised but gives me the flexibility and features of a local repository. I of course, therefore, looked at git-svn (which comes as part of the standard Git install).
This brings us neatly to where I am now. Git is a fantastic piece of software, but the fact that I fundamentally disagree with the principles under which it is designed makes me very hesitant to invest hugely in it. I also dislike the fact that my workflow currently relies on a “plugin” to communicate between two systems, one of which is far less sophisticated than the other.
So recently I undertook a lot of research to see if my ideal SCM system existed, one which would allow me to have a local repository as well as committing to a centralised one and also provided me with all the new innovative version control features.
While undertaking this research I made a discovery that worried me. The question of centralised vs. distributed has really polarised people and there was very little occupying the middle ground where I sit firmly. No one seems to want to make a nice hybrid of the two, but instead make a one-sided system and preach about why it is the best way to manage source code.
Everyone that is, except Bazaar. Bazaar, is an often overlooked version control system, and one that seems to be the only one that is acknowledging that a middle ground exists. Although it does concern me a little that it describes itself as a DVCS, maybe its because that’s what all the cool kids are these days. However, to me it seems to nail what I see as a much overlooked facet of source control: flexibility. The directly supported workflows in Bazaar are simply unrivalled by any other system.
Sure there are plugins or extensions written for other systems but to know that you are using the software in a way that it has been truly designed to support is very gratifying. However, I am using git and git-svn for all my work privately and at work, why not Bazaar if I think its so great?
The answer is interesting. The first explanation is relatively simple. We use Subversion at work and that isn’t changing at least for a long time and therefore what I use must work, and work well, with SVN. Bazaar still requires a plugin to communicate with Subversion and bzr-svn is no where near as robust as git-svn which. Beyond that, if you remove the advantages of using Bazaar on both the server and client side I gain nothing using it rather than Git on my local machine.
This brings me neatly onto the second reason. Git has spoiled me in terms of speed and Bazaar just feels too slow when doing merges. Looking at the development of Bazaar it seems that they are at work on a whole new engine on the back end that should really bring speed up but right now it feels sluggish. It’s still a speed demon compared to Subversion, but use any one of the newer systems and that is the case.
The third reason is user-base. Bazaar has seen very little uptake compared to Git and Mercurial. Ubuntu is the only big name using it and there is one website offering hosting: Launchpad. Which only hosts open source projects. Considering the trust you put in a source control system, having a nice large user-base to fall back on when your in trouble is an important safety blanket. How many Bazaar experts do you know? Compare that to how many people you know who are a dab hand with Git, yep….. exactly.
So what I have just done is tell you why Bazaar is my ideal SCM system and why not to use it. Which nicely illustrates my frustration with how things are at the moment. Git is the only system I’ve tried that performs in a way that I am impressed with but Bazaar is the only system that seems to be going down a design path that I like. I can only dream of a world where Linus decided to acknowledge that my precious middle ground existed and extended Git to support centralised elements. Until then I will keep plugging away with git-svn.
Its been a while now since the “