Setting Hugo Version for Netlify

After deploying my blog via Netlify I noticed some pieces were missing. Turns out I needed to tell Netlify which version of Hugo to use during the build.

Adding the following to the netlify.toml file was all it took.

  HUGO_VERSION = "0.23"

A test post using Netlify CMS

One of the things preventing “normal” people from using a static CMS is that there’s not a comfortable way to for them to edit and preview content. I myself prefer editing markdown in a local text editor. Most people don’t work well that way.

This post is being written in my browser using Netlify CMS. When saving, it’ll create a new markdown file in the Github repo and Netlify will automatically re-build the site and push it to the Netlify CDN.

Update 2017-03-17 It worked very well. The only thing I still need to deal with is adding Tags to the CMS UI. I tried using a “String” type but that put single quotes around the entire thing, breaking the build. Oh well. This is a nice way of editing existing posts via an easy-to-use web control panel, for times I’m not at my desktop computer.

Netlify and Hugo

I upgraded my iMac to the latest macOS Sierra beta. I thought everything was working fine until I tried to publish a short blog post about the experience.

My Hugo and/or Go installation was broken so I could not build my site. This meant I couldn’t publish to my blog. Ironic, no? Rather than waiting for things to be fixed, I decided to find a way around the problem.

Enter Netlify.

I’ve wanted to use Netlify again ever since they’d removed the builds-per-day limit. (I tend to make a lot of corrections after publishing). I added my site’s configuration to Netlify, pointed it to my Gitlab repo and added the appropriate DNS records. Five minutes later the site was built (via Hugo) and deployed to Netlify’s servers and CDN.

Now, every time I commit to master and push to Gitlab, Netlify automatically builds and deploys everything for me. I’m a fan of simple, static files on a server I control, but Netlify offers benefits that make it worth giving up a little control. For example, I can fix a typo by editing a file using the Gitlab web UI and the site will be built and deployed automatically. This lets me make edits on my iPad, which can be handy.

Continuous Deployment, a CDN, easy rollbacks, CLI, free one-click SSL, and a generous free tier. Pretty nice, Netlify.