Hello, this is a blog.
This blog now exists for a few reasons. Firstly, I wanted a homepage on the internet, something to make use of the domain I use for email. Secondly, I was looking for an excuse to try a static site generator. Then it slowly dawned on me as I browsed Hacker News, that many interesting notes on people’s experiences and guides to technologies were simply written as posts to their blogs. So why not follow suit and dabble in a tech blog?
Before Static Site Generation
I’m sure this isn’t news to you, seasoned coffee-drinking tech professional, but for the benefit of others: There once was a time when small websites were lovingly hand-crafted as HTML in a text editor. (Quietly glossing over the poor souls wrangling Dreamweaver and Frontpage into anything useful.) Pages begat pages, and nightmares were had when the whole site had to be a different shade of puce.
Several million hacks and missing MySQL backups later, the people grew tired of big CMS. They pined wistfully for the days of writing pages in a text editor, yet were spoiled by the separation of content and design that Wordpress et al taught them. And so a new dawn was ushered. That of the Static Site Generator!
The New Static Utopia
There are more static site generators than you can shake a stick at, but they all work in a similar way. You start with a themed template of page parts, write your content as a pile of human-readable text in Markdown or similar, then run a program that blends it together and spits out a bunch of boring HTML files. Then you can serve them statically like it’s 1996! So long, SQL injection hacks! Welcome back, simplicity!
This means you can store the whole site as a bunch of text files and a handful
of HTML/CSS/JS in a git repository, even hook up the
generator to publish the site on a
git push to your host if you like.
Anyway, This Blog
After eyeing up the options, I went with the fast and simple up-and-comer of
the static site generator world, Hugo. Getting started is
a matter of dropping Markdown text files in
content/posts/ and configuring
another text file. Through sheer laziness I also chose to let
Gitlab host the whole thing for free, which saves me
writing git hooks and configuring hugo to run as a daemon and so on.
(Github also freely hosts static sites that update on git push if you use the popular Jekyll generator.)
Then I browsed the available themes, found a nice one to start from, then tuned all the colours to my taste. Now I’m thinking about comments, but I don’t want to drag in the entire Disqus parade. Maybe Isso, but it requires something that isn’t Gitlab server to run on. For now - first post!