Subversion (Mac)

Setting up Subversion can be a royal pain in the ass. That’s why I decided to write this mini-guide that tells you what to do, it’s not the most “official” way of doing things, but, if you’re going to live your life by the book then I’m telling you now — don’t read this guide.

I’ll be setting it up on a mac with Coda, Versions and Dreamhost with subversion on a custom domain (you can easily just replace this with beanstalk or another host). If you want to do it on Windows then I can’t help you.

Step 1:

Download Coda — it’s $99, just buy it.

Download Versions — it’s €39, you can get by with the demo.

Step 2:

Buy yourself a domain name specifically for the job of hosting your subversion, or just use a subdomain on an existing domain.

Setup subversion on your domain of choice. On Dreamhost Panel it’s Goodies > Subversion and it’s very obvious what to do here.

Step 3:

Versions can be a bit “too simple” straight off the bat, just setup a new repository and enter the url to the subversion stuff you setup on the Dreamhost account (or your Beanstalk account if you’ve got money growing out of your ass).

The username and password will be the ones you have with your host. It should connect fine, if you’ve bought a new domain you might have to walk around the block or fire up your 360 to kill some minutes before it’s propagated to your webhost. NOTE: Don’t forget to put the nameservers in for your dreamhost account, otherwise you’ll have to take another walk.

Step 4:

Import your project, (right click, import) e.g:

Import

OSX has a funny way of filling every directory with hidden files and subversion freaks out about them sometimes. Just open transmit or whatever you use to show hidden files and delete the offending items, then, try again.

Step 5:

You’ve made a copy on the remote subversion host, nice. Now we want to “checkout” the project with Coda. It’s pretty easy, just go into the site settings enter the subversion details (same as the ones we used for Versions).

NOTE: Make sure you’ve chosen an empty folder for your site

Step 6:

Once you’ve got the source to your local directory (this is called a “working copy”) you can go ahead and enable versioning. Do this by going back to the site settings and tick “Enable Versioning” — enter your details again.

Now when you make a change to a file, a small “M” icon will appear.

Commit

Click on this and leave a message, then you can continue working like this on future files. Additional subversion control, such as file locking is in the File menu.

You can close Versions after the initial import to the repository, you don’t even really need to buy it as long as you’ve bought Coda or you want to use advanced Subversion commands.