Subversion is a bit lacking on the merging and branching front in comparison with some of the newer distributed version control systems, but it does make working with large projects easy. The single biggest reason for this is sparse checkouts.

At work we have a source tree that contains artwork, documentation, the source for all the third party libraries we use and compiled versions of these for multiple architectures and platforms (32bit, 64bit, windows, RHEL4, RHEL5 etc). This makes the full checkout rather large and there are many times when you only need a small fraction of all the files.

The problem with sparse checkouts is that it can become very laborious manually setting one up for anything beyond a few directories. For more details on the basics see here. As with many tedious tasks – computers can help!

I put together a little script for helping with this – get it here. I hope it’s useful and keep reading for more details on how it works.

In Action

The final version of the script makes doing a sparse checkout as simple as doing an standard checkout:
./checkout.rb svn://server/trunk

To checkout using a named subset of files:
./checkout.rb --map documentation svn://server/trunk

To checkout using a locally defined subset of files (rather than a subset stored on the sever):
./checkout.rb --map local.yaml svn://server/trunk

Continue reading

For 2.5 yrs work has made use of a Kolab server I set up, but recently it has been taking up too much of my time to maintain. Google Apps was chosen as the replacement, so the problem then became how to get 39GB of data uploaded to Google over a fairly slow ADSL link, whilst keeping everyone up and running as much as possible.

imapsync seemed to be the tool of choice for a lot of people doing migrations of IMAP users, and it has done a very good job here too. I used version 1.311 from source rather than the older package provided with Ubuntu at the time as it contained various fixes for Google’s IMAP servers.
Continue reading

Overview

I have a Kurobox HG, that has been running Gentoo for a while now. After getting fed up with the waits for compiling packages I decided to switch over to Debian.

Only having SSH access to the box makes switching OS a slightly more tricky prospect than a standard OS switch or upgrade.

The basic plan is:

  • Disable swap
  • Install a very basic debian system onto the swap partition
  • Reboot into the basic debian system
  • From the basic debian system, install a debian system onto the main partition
  • Reboot into the basic debian system on the main partition
  • Reformat and enable the swap partition
  • Finish configuring the new system
    There were a few tricky steps along the way, so I’ve documented all the steps below.
    Continue reading

GNU Screen is a fantastic piece of software when working with only an SSH connection.

It allows you to run multiple virtual terminals in a single window, but most importantly allows you to detach from the session. By this I mean you detach from the screen session, close your SSH sessions and whatever was running in the terminal remains running. You can then SSH back in at a later date, reconnect to the screen session and be right back where you were. Brilliant for any long running jobs like large compiles when you don’t want to keep the SSH session running.

For more details take a look here