Blueprint style diagram showing a Teapot.

A teapot, cut in half. Sort of.

I’ve had a mysterious broken page on this site for a while - but been too busy to look into it. My Comprehensive Linux Backups with etckeeper & backupninja article has been refusing to load, and returning a weird HTTP 418 Unused status code instead. I finally made the time to figure out the cause.

It turned out that this was being ...


Read More

This site has been generated using Pelican 3.3 for over two years - and I finally found some time to upgrade to the current version of Pelican, 3.6.3. This is how I did the upgrade.

I decided to be lazy and do the upgrade in-place, instead of creating a new virtualenv and copying the content & settings over. Luckily, this worked out OK, after a bit of fiddling around.

I also decided, rather cavalierly, to upgrade all the packages ...


Read More

We use CentOS VM’s at work to emulate our production environment - and it took me a while to figure out how to get the VirtualBox Guest Additions to build reliably on CentOS 6.4/5. This is what I’ve currently settled on as a reliable method.

First, make sure that you’ve got the kernel headers and tools installed that you need to build stuff:

sudo yum update -y
sudo yum install gcc kernel-devel kernel-headers dkms make bzip2 ...

Read More

Taken from my Wife’s office window, around 10am.

The weather was great this week - crisp and autumnal, with beautiful sunshine all week. It snowed a little on the local mountains and Cypress Mountain has opened for (limited) Skiing already, using the lower temperatures to make lots of extra snow. Whistler also opened this week, along with Grouse.

Taken from my Wife’s office window in the afternoon, during the Golden Hour, which is now around 4pm.

In other, even ...


Read More

To create image thumbnails from a PDF document, run this in a terminal window:

convert -thumbnail x300 -background white -alpha remove input_file.pdf[0] output_thumbnail.png

The parameters to convert do the following things:

Parameter Effect
-thumbnail Similar to -resize, but optimized for speed and strips metadata.
x300 Make the thumbnail 300px tall, and whatever width maintains the aspect ratio.
-background white Sets the thumbnail background to white.
-alpha remove Removes the alpha channel from the thumbnail output.
input_file.pdf ...

Read More
A dummy placeholder image, 200x200 pixels square.

This figure has automatic figure numbering.

I had a feature request for automatic figure numbering, like latex. I was revamping this plugin for Pelican 3.3 anyway - and this didn’t seem too hard - so I decided to add it.

So, the Better Figures & Images plugin now supports automatic figure numbering. To enable this for all posts, just add this to your config file:

FIGURE_NUMBERS = True

If you want to enable this per post, just add this to the metadata ...


Read More

There are quite a few changes in Pelican 3.3 - most of them minor, but a few which might mean making some changes to your site in order to upgrade. This is what I did to move my site from Pelican 3.2 to 3.3.

The change that had the biggest impact and took the most work was around image linking - caused by a combination of things. I think I was doing it wrong before and things changed in ...


Read More

I’ve recently been corresponding with Denny Dias, from Brazil, who’s converted his blog over to Pelican - and we’ve been helping each other out a bit with building themes and whatnot.

He’s written up his conversion & theme building process - and was generous enough to credit me after he borrowed some of my theme’s logic, from this blog’s GitHub repo.

As he’s such a nice guy - and as I’ve just borrowed his tagsort jinja ...


Read More