Blog | Comics | YouTube | EmacsCast | Bookshelf | Twitter | RSS
I have changed the setup for this blog from Jekyll + Github to Hugo + ox-hugo + Netlify. The main goal was to be able to write blog posts from within Emacs and reduce as much traction as possible. Also, Org mode is much more comfortable to write in compared to any Markdown editor I’ve tried.
I’ve been using Jekyll and Github pages for a long time, and it was generally a good experience. I don’t have big complaints about Jekyll. It can be a bit clunky when it comes to things like tags, but I don’t use them anyway. My Russian blog is still powered by it. One thing that is never fun — the need to manage Ruby environment and dependencies. Some people prefer to encapsulate everything into Docker containers, and I’ve tried that with Jekyll as well, but the overhead complexity is not worth it.
I was using Sublime Text or sometimes iA writer to write posts. The whole process was full of small steps that added friction. I fully acknowledge that this sounds like “the tools stopped me from being a prolific blogger, if only I had better tools” fallacy.
This is how it looked like for the most part:
2018-01-11-be_bored.md). I have a bash script to quickly create a new file with some front-matter inserted by default.
Sometimes thing go bad and Github build fails. There is no clarification, and on rare occasions I had to contact support to find out the actual build error output. GitHub’s support is excellent, but this process is no fun.
Now I use Hugo static site generator, but don’t write Markdown myself. I write in Org mode (I talked about it in EmacsCast episode 2) and use ox-hugo to generate Markdown files for Hugo to then generate static HTML. Yeah, seems like too many moving parts for the sake of the simplest page possible, but it works remarkably well and — worst case scenario — if Emacs or Org or ox-hugo go bad, I can go back to essentially the same process as before.
This is how it looks like:
And with Org capture I can create a new draft from anywhere in Emacs with two key strokes.
There are several small things that make Hugo nicer than Jekyll for me:
hugo server -D --navigateToChangedthe browser navigates to the changed file automatically and refreshes the page on each change. No need to refresh the page manually! Instant Markdown preview.
While this transition was mainly performed due to workcrastination, I’m pretty happy with the results. Hugo itself wouldn’t be the reason to switch, it’s the combination of Org + ox-hugo + hugo that makes it all worth the hassle.
Writing in Org is arguably a more pleasant experience compared to Markdown. Being able to integrate blogging into the same program that is used for planning, programming and long-form writing is very nice.
The whole blog setup, including this custom theme is available on Github.