<- Back

posh.wiki / blog


Making a terrible generator

2025-02-15

For a good while now, I've wanted a better way to organise the content I write for this website.

Previously, it was just a series of HTML files. There was some flask templating going on to import CSS and such, but aside from that, each page had full HTML. A simple frozen_flask generator stuck templates/blog/* into build/blog/*.

Not only does this use a lot of storage space, it's also difficult to change. If I wanted to update the theme at any point, including retroactively, I would have had to edit each file by hand, which would get very tedious, or spend even more time failing to automate the process.

There are also a lot of limitations in using a generator (or maybe it's just my lack of skills in this particular stack). I'd like to be able to manage a lot more information than I was able to.

So, now blogposts (and bookshelf posts!) are put here using a custom generator function. The content of previous posts has undergone zero changes, and all the HTML embedded in their content is still fully functional.

The only challenge now is that the generator struggles with static files. I'm vaguely aware of how to fix it, but it's 10PM, and I'm tired. (Yes, I'm old, by bedtime is 10).

However, this opens up possibilities for several new features, like: * Custom naming in the list page * RSS feeds * That's all. I don't know why I said several.