Yet Another Generic "Middleman Powers My Blog" Post

It's almost compulsory when someone starts a new static blog to post a "what powers this" article, and who am I to break tradition? So here goes.

The Engine

I've decided to use Middleman with the blog extension rather than Jekyll. After doing some research (ie googling Middleman vs Jekyll) a lot of people seemed to prefer the former over the latter.

As I had zero experience with static site generators I just decided to go with the flow (after all, when has that ever gone wrong) and am quite pleased with my decision. Despite having no Ruby experience at all setting everything up was pretty straightforward and uneventful.

Design

For the first version I decided to be a good developer and use Bootstrap as everyone else was using it. However in the mean time Foundation became the new cool kid on the block, so naturally i switched and haven't look back since.

Even though it's supposed to be minimal, even someone like me with the aesthetic skill of a colour blind accountant is able to build something presentable. Ripping off a the design of the blog template and a couple of sites slightly helped a lot too.

For the templating itself I switched from haml to slim as I found it a little less convoluted.

Hosting

At first I contemplated hosting this on the CloudVps Object Store as I already rent a vps from them and am quite happy with their customer support. Also they're significantly cheaper than Amazon S3. Then the cheap little dutch boy in me overpowered my reasoning and forced my hand to host on Github Pages as it's free. Setting up the github side of things is pretty much idiot proof.

Deployment

Middleman has a plugin to deploy to Github Pages, but rather than using that I decided to give Wercker a shot as I've heard good things and at the time of writing it's free. Setting up wercker to deploy your project to pages is pretty straight forward as well. The wercker.yml config the blog uses is pretty straightforward:

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
box: wercker/ruby
build:
    steps:
        # Execute the bundle install step, a step provided by wercker
        - bundle-install
        # Execute a custom script step.
        - script:
            name: middleman build
            code: bundle exec middleman build --verbose
deploy :
  steps :
    - lukevivier/gh-pages:
        token: $GIT_TOKEN
        basedir: build
        domain: higherlearning.eu

There isn't really much more to say. Hopefully in the future new articles will be a bit more technical and a little less explaining the painfully obvious and trivial.

comments powered by Disqus