So zerosleeps has been chugging along as a static, generated website since early 2015. Unfortunately Octopress, which I use to generate the site, hasn’t been updated for several years. I haven’t helped matters - I don’t think I’ve once attempted to update any of the dependencies. It doesn’t really matter because the end result is still perfectly legal and valid HTML and CSS (although I am serving version 1.9.1 of jQuery which is from 2013).
Anyway, I’m starting to get nervous about using outdated tools to generate the pages. Octopress was written for Ruby 1.9 which has long since stopped receiving maintenance updates. There’s a dependency on Jekyll 2, while the latest version of Jekyll is version 4. Rake is now on version 13 but I’m pinned at version 10.
I’m thinking Django. My goto for this kind of stuff used to be Rails, but I’m a bit over Rails these days. It looks like Rails 7 takes a serious stab at resolving a lot of the front-end nonsense that’s in Rails 6, but Rails 7 hasn’t been released yet and the more I use Django the more I like it. It’s the explicitness that attracts me - something which is very much missing in Rails between autoloading, deep class hierarchy, and Ruby’s wild-west require system.
There’s also the matter of my reading log, which at the moment is a single static Markdown document. It’s just screaming to be turned into a proper database entity.
So what would I need to do to make this happen? Well each post is an individual Markdown document with some YAML front matter. Should be pretty straightforward to convert and pop into a title + date + body model. I’ve used Python-Markdown before, and the only issue I think I’ll have is with Octopress' custom
img tags. I don’t have too many posts with images, but now I’m thinking about it I probably would include images and photos more if they weren’t such a pain - I currently manually create different sizes of each file and copy/paste filenames.
I’ve got heaps of posts with blocks of code as well. Might have to get Pygments involved somewhere…
URLs are important. I don’t want to break any external links, so I’ll be keeping the current “blog/<year>/<month>/<day>/<slug>” structure around. Maybe just for backwards compatibility though - the granularity of the current structure is unnecessary so perhaps a simpler default?
There’s the aforementioned reading log, which will be a pain to convert and transform. While there is structure to each entry, it’ll be a pain to programmatically parse. There are also some entries that don’t have full dates, so can’t be represented by a
datetime object. I’ll need to think about that.
The only other thing I can think of at the moment is RSS feeds - I currently have a JSON feed (which should be easy peasy to replicate), and an Atom XML thing, which might be trickier.
And I’ll for sure be using a CSS framework, likely with minimal changes because I suck at visual design.
Let’s see what happens, and how long it takes me!