I've got hobbies and dang it I'm gonna write about 'em. Since the pandemic began, I've gotten into all sorts of weird shit that I never thought I'd be into. Running, blockchain tech, impromptu road trips, and now blogging. You're gonna hear about all of it here, but first let's do the obligatory "blog tech" post.
It's all open source. View the repository on GitHub.
This blog is hosted by GitHub Pages because I didn't want to pay for EC2 or set up a kubernetes cluster. I don't hate myself enough for that.
I'm running Eleventy for the whole shebang. Templates are written in Nunjucks which, to be honest, I don't care for much as a templating language, but it's the default for Eleventy and I wanted to start simple. It's growing on me a little as I use it more.
Posts are written in markdown. This is good because it will force me to use markdown and eventually I'll memorize the syntax for inserting an image.
Eleventy itself has been pretty cool. It was recommended to me last year by my old colleague Kai. I haven't dove too deep in yet, but the community seems nice and there are plenty of plugins for more advanced features like RSS and such. The last SSG I used was Jekyll, but I was never a fan of Ruby and it never "felt good" to me.
The biggest gotcha with Eleventy for me was the dates being off by one day. I solved this by fudging the local time and offsetting it by the UTC offset:
eleventyConfig.addFilter('readableDate', date => {
const offsetSeconds = date.getTimezoneOffset() * 60 * 1000;
const utcTimestamp = date.getTime() + offsetSeconds;
const utcDate = new Date(utcTimestamp);
return format(utcDate, 'EEEE MMMM d, yyyy');
});
There is almost definitely a "better" way to do this. Oh, and the syntax highlighting? There's a plugin for that.
I am using Skeleton for the boilerplate and responsiveness. It's simple, lightweight, and works but is no longer maintained as far as I can tell. I do some very minor overrides in plain old CSS, but it's mostly Skeleton. Dig those light blue links.
Icons are open source from Feather Icons.
The build and deploy process is automated using GitHub Actions and once again I am standing on the shoulders of a great community. I followed this guide on LinkedIn from Léa Tortay to get it set up. Thanks Léa!
Because I want to know if anybody is actually reading this and I don't want to sacrifice anyone's privacy for my own selfish curiosity, I am using Cronitor (formerly Panelbear) for analytics. It's privacy focused and doesn't use tracking cookies or garbage like that. It's created by Anthony Simon who I learned about via their very very good blog post The Architecture Behind A One-Person Tech Startup.
2021-05-12 Added citation for icon library. Noted Skeleton is no longer maintained.