.NET, Archive, Software Design, Virtualization
     

Source Control Is For Toddlers

You read that correct, source control is for toddlers. Not for toddlers to use, but rather to protect us from them. Surely the sole purpose of products such as Subversion, TFS, et. al. was to protect society from these pint sized keyboard loving terrors.

 

Of course I mean all of that tongue-in-cheek, as I love my son. However they do have a way of deleting or overwriting entire portions of code in a blink of an eye. It is a good thing that I use Subversion for all of my personal projects, otherwise that little guy would have cost me untold hours of work. Here is how I practice personal source control:

Create a virtual machine.

The low cost of VMWare and Virtual PC make it foolish not to use them. I personally find it attractive to have the Subversion server running in a VM on my laptop so that backups of the VHD encompasse the entire source control. So recovering after an accident (or hardware failure) is seconds not hours.

Commit often.

You never know when your toddler is going to delete something. For that matter it is sometimes difficult to know when your toddler DID delete something. Checking in often not only provides detailed documentation on what you were working on last, but it also provides an audit trail for when something changes in your working copy. I try to never leave uncommitted code in my working copy longer than a single development session. So if I come back to my project in a few weeks there are no half finished ideas. Additionally coming back to a project with uncommitted code makes me question how, who, or what changed that code.

Take Risks.

You heard me, take risks. Don’t be afraid to try out crazy ideas with your working copy. You can always revert if it doesn’t work out. If you’re like me having a toddler also means there is a limited amount of time to spend on personal projects. So why waste that time pondering if what you are about do with your code is a good idea? If you are already practicing good source control habits then the only thing at risk is the code you modify during your “experiment”. I find that coding without fear actually increases my productivity. Sure I revert some bad ideas every now and then, but I also keep several good ones.

So if you aren’t already practicing personal source control, what’s holding you back? Download a copy of Virtual PC (its free!). Then snag a copy of Subversion and TortoiseSVN (again both free). For those strapped for Windows licenses you can even run (darn I say) Linux in your VM for the Subversion server. What are you waiting for, your toddler to delete your code?

Never miss an article! Subscribe to my newsletter and I'll keep you updated with the latest content.

 

About Jason

Jason is an experienced entrepreneur & software developer skilled in leadership, mobile development, data synchronization, and SaaS architecture. He earned his Bachelor of Science (B.S.) in Computer Science from Arkansas State University.
View all posts by Jason →

Leave a Reply

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