Unless you've had your head in a watermelon for the last few years, you've undoubtedly heard of Subversion. It is the One True Version Control Systemâ„¢. And if you read my last post you'd know that I know there is no black and white etc etc. Suck it up, princess. It's my blog, I'll contradict myself whenever I feel it's necessary. Or not.

There are literally billions of open-source style projects out there using Subversion as the version control system. If you're any sort of developer, you really should have at least the client installed on your workstation. I find it invaluable for looking at other people's code when I'm trying to solve problems.

Just being able to open a command line, switch to a temp dir and pull down the source to another solution over the net in a couple of minutes is wonderful.

I also believe that there ain't no such thing as a free lunch, so you should always learn to do things by hand first, before you use the automatic version.

Manual installation

This is so easy, it's stupid. Go to the Subversion project homepage on tigris.org. Now, from the menu on the left, just underneath "Getting Subversion", click the "Downloads" link. Now, scroll down until you see the Windows flag. Under there there'll be a couple of options for downloading Windows binaries. Unless you have any real idea what you're doing, just pick either one of them. It won't matter.

Wait for the download to finish, then unzip the file. In there, you'll notice a bunch of folders. What you do from here is probably a little personal.

I normally have a folder on my data drive called "Development", and right inside that another folder called "Tools" that I use to hold the binaries for all the tools that get copied into my source trees.

I've made a folder under there called, funnily enough, "Subversion" and pasted the contents of the zip file into it.

You'll notice the conspicuously missing version number. I do this so I don't have to keep editing my path settings every time they release a new version. I just accept that the version in my "Tools" folder is the most current I have.

So, based on that, the last change you have to make is to add the "Subversion" folder to your path variable. Once you've done that, you should be able to drop to the command line and issue the "svn" command and have it tell you to try using the "-help" switch.

If you've got here, you're good to go.

Automatic installation

Really? That was too hard? Okay. In the same place you just downloaded the binaries from, there were a bunch of files that ended with "-setup.exe". Go back and grab one of those, then install it.

Once it's downloaded, just run it and away you go.

Testing it all out

If you want to check that your Subversion client installation is working, just pull down some code from the web. Start the command line interpreter, change to the root of your development directory (mines called "Development", strangely enough), then execute this command at the prompt:

svn co https://cuyahoga.svn.sourceforge.net/svnroot/cuyahoga cuyahoga

If everything's set up correctly, you'll be prompted to deal with a non-trusted security certificate (just accept it temporarily for now), then reams of beautiful code will be pulled out of the cloud and on to your workstation.

This code, by the way, is a great example of how to write software with .NET. It's well structured, comes with a complete build script (you'll need NAnt - something for another post), and leaves you with a nice CMS for your website. 

Next steps

Next time, we'll talk about setting up the Subversion server manually. It's not that hard to get it up and running basically, but the automatic tools are actually much simpler.