Further renovation


Hey folks! Over the past week or so I’ve been playing around with shifting my site from jekyll to nanoc. This post is mainly to mention that in the next few days I’ll probably be shifting the site from one format to the other.

From what? To what?

Jekyll is a static site generator (SSG) written in ruby. Nanoc is also an SSG written in ruby. They’re both ways of turning a collection of documents into a static website, but I’ve recently been wondering if jekyll was the right fit for me. Last week, in a fit of pique, I decided to work out how hard it’d be to switch my current site over. The answer: not so hard at all.

Why not jekyll?

Jekyll is an excellent SSG with a great community and lots of support - but I don’t think it’s quite the right fit for what I want. Several bits of jekyll “just work”, which is great for people who want to get blogging right away (as I did when I installed it) and its github support is excellent. Unfortunately, the cost of this is ease of customisation. Some of the slightly squirrelly things I want from my site are…tricky…to accomplish in jekyll, just by virtue of the jekyll team having made design decisions much further up the stream.

In short: sometimes I have to work quite hard to get jekyll to do the things I want it to, and a lot of the time it feels like what I want jekyll to do is not quite what the designers intended it to do.

So why nanoc?

I looked at a couple of different ruby-based SSGs to start with, and played around with a couple, seeing how easy it was to get a giant folder of markdown files into the blog-type format I wanted. I ended up settling on nanoc, a nice small rule-based SSG whose routing/compiling DSL was reminiscent of rails or sinatra, but also promised great power in how I laid out my site.

Nanoc took a bit longer to get used to than jekyll did. The rendering base is a bit more complex. But, once I fully understood the layout, it was suddenly much more powerful in terms of creating the pages I wanted. I feel like nanoc’s filtering system is more robust than jekyll’s, which means that a lot of the hoops I was jumping through before suddenly appear a lot less hoop-like. It’s little things. But it’s the little things that make the whole thing feel smoother.

What to expect

At some point, I’m going to be shifting the site over (assuming the upload to S3 from the nanoc dir works out as expected). Here are some immediate changes:

  • All the blog links will break, as I switch from .html article endings to “pretty” URLs. The 404 page should hopefully handle most of these with relative grace, but no guarantees.
  • Category feeds will be relocated. If you’re subscribed to these, get ready to change them.
  • The site may see a bit of a cosmetic change, as I freshen stuff up.
  • Some pages may disappear. Some pages may appear. Other pages may shift. This will hopefully be minor.

Overall, I’m hoping to keep most of the site intact, but the back-end switch will make future projects and expansions that much easier. Depending on spare time, I may also write about some of the hacks I’ve done to make nanoc work how I want it, so keep your eyes peeled.