The story of this blog
Or how I learned about static-site generators
Jun 01 2010

Until recently I wasn’t much of a blogger. Not withstanding a couple of articles on trust ratings, I didn’t feel like I had anything to say that was profound enough to publish (still don’t but do read on!). I had set up something on blogger.com but was using it more as an OpenID server than anything else!

When I started my return to development, I began to appreciate how valuable it is to quickly document a trick, idea, or discovery. Googling for help when I was looking to get unstuck from a code related problem invariably lead me to posts of other developers. I also noticed that a lot of people in the Ruby and Python communities use their a blog as a mechanism for establishing themselves as professionals – a GitHub (or google code) account and a blog appear to be the business cards of the developer. So, I set out to resurrect the iNK blot with the intention of writing about my journey back to development, and, to document tips and tricks that other developers might find useful.

I looked around a bit and found that since I had mucked around with blogger, there were several options for creating quick and easy blogs. I checked out the usual suspects including Wordpress, Posterous and Tumblr, and I also saw several references in the Ruby community to the blog like a hacker approach. I guess it depends on what you are setting out to do but my simple take on things is that if you want to write prose, throw in images, videos, etc., then a service like Posterous or Tumblr is probably what you need. Editing a blog is easy on these platforms. You can concentrate on the content and never worry about hosting issues, but you also need to abdicate control of the minutiae of the style in which your pages are presented. If you want to present code blocks and get fancy with the features of HTML5 and CSS then you will likely find these services to be too constraining.

Anyway, I set myself a project to investigate further. I wanted to know more about what it would take to build a blog using Ruby tools and I was curious about whether this would then be too complicated and turn out to get in the way of writing – i.e. would it be a productivity blocker.

I started with the awesomely tiny toto which I discovered in an article by Peter Cooper on Ruby Inside. Toto will get you blogging in 10 seconds! It is minimalist in its approach, elegant, and it integrates neatly with heroku and git. I had a lot of fun playing with it and when I noticed that it is based on Scanty, I went off to see what this was about. Right about at this time I was also curious about Chris Wanstrath’s template language Mustache and lightweight alternatives to Rails like Sinatra and, found Scanty’s cousin Hackpad which uses both Sinatra and Mustache. Unfortunately, I found the scantiness of documentation on Hackpad to thwart my meager Ruby powers – I found it to be not so easy to set up after all.

The aforementioned Ruby Inside article also made reference to Jekyll, mentioning that it includes a blog-like system but at heart is designed to cope with full sites. Well, Jekyll is very well documented and owing to its connections with GitHub (Tom Preston-Werner, author of Jekyll, is also a co-founder of GitHub), comes with many examples of its use. It is used by GitHub to power its GitHub Pages feature that allows for publishing content in a GitHub repository to the web. Tom has written about his motivation and experience with creating Jekyll in the article, “Blogging like a hacker” and, presumably, is attributed with coining the phrase.

Eventually, I settled on Jekyll because I liked the fact that it is actively used and supported by so many of the GitHub community. I looked around the Sites list in the Jekyll wiki pages and settled on Alex Payne’s weblog as a starting point. Incidentally, I had no idea at the time that I was borrowing from such as strong member of the tech community – if you want to know more, check out his latest venture BankSimple. I had a prototype going in a few hours and found that rolling in google analytics, disqus comments and fonts from Typekit was ridiculously easy. By the end of the day I was up on GitHub pages and happily blogging like a hacker! The only hit to productivity appears to be that I have not yet settled on a text editor!

When I started writing the post on the flickr-notifier, I wanted to put up code snippets and so went looking around for examples of how to do this. Since then I have used CSS and HTML by Andrew Carter.

As I use Jekyll I am beginning to better understand Peter Cooper’s comment that Jekyll is designed to cope with full sites. I now see how to use Jekyll to create and easily maintain a static (i.e. not database driven) website. I am pleasantly surprised by this side-effect! See this post by Simon Pascal Klein for more on this topic.

Since learning about Jekyll I have heard of similar static-site generators such as nanoc and having spent some time in Python/Django land, run into Jekyll’s evil Python based twin, Hyde!

Things I would like to do on the topic of site generators:

  • Play around with Jekyll – look into replacing its Liquid template system with Mustache for instance
  • Learn more about nanoc and better understand what it does differently from Jekyll
  • Revisit Hackpad – see if it is suited to generating lightweight dynamic websites
blog comments powered by Disqus