Version control and the single developer
November 14, 2012 in Technology
I routinely chat with solo developers, and eventually we talk shop, and the subject of version control comes up (OK… sometimes I bring it up!). I’ve noticed a trend in the past couple years of solo developers more and more not using any sort of version control, and something about that bothers me, although I can’t quite put my finger on it. It may be because the majority of people I know not using it have never tried it in the first place, and are missing out on a lot of benefits based on myths or misconceptions.
Common justifications I’ve heard include “Well… I’m just a single developer, I don’t need it” and “I already have backups running”. This demonstrates a real lack of what benefits version control offers, so I thought I’d share a few of my own reasons why I use version control.
Branching allows me to develop different sets of code on the same computer without fear of losing or overwriting code that I’m not sure I may need to keep or change.
Specifically with git, this is extremely fast and easy to do. The idea of branching is to create a parallel code tree forked/branched from a specific point in your main codebase, and work on it without disturbing any of the code in the main codebase (or.. the main ‘branch’ if you will).
Subversion offers a type of branching, but if I remember correctly, it essentially involves making copies of all existing files. When branching in subversion on large projects, this can sometimes take several seconds or even minutes (2006/2007 I recall some large projects taking > 3 minutes to branch on the hardware I had). This can severely interrupt your flow when working, and once you experience branching in git (or similar functionality in other distributed version control tools like mercurial) you’ll wonder how you ever survived with subversion.
Visual progress / transparency
Most of my clients aren’t technically savvy enough to read code, but they can still watch progress in my version control repository – they can read commits and see what problems I’m working on, even when what I’m working on isn’t visual or front-end related. I don’t use this in place of issue tracking or written and verbal status updates, but it’s another data point they can look at to validate I am in fact working, even when it’s not apparent. Additionally, they can have someone else look at the code and changes to verify I’m actually doing what I say I’m doing and doing it properly. Have I ever had anyone do this? I don’t think so – my clients tend to trust me (and vice-versa) but the option is there – there’s no secrets as to what/how I’m doing on the project.
Even though 95% of the dev work I do is on my own, by having everything already in a version control system, getting assistance from others is that much easier because they can grab the repo code and dive in. ”yes, but you can just send your code to them”. I can, but they can’t see my progress or history to know what I’ve tried and not tried. When they want to send back a fix for me, they can branch and push a separate branch for me to review and test before merging in with my other code. It’s far cleaner and faster than emailng around source files and diff patches.
If you’re using version control as a solo developer, what do you use and why? If not, why aren’t you using version control? Does it seem too cumbersome? A waste of time?