Posted on 29th January 2025
How I built a lightweight blog
I've been writing this blog for a couple of years now and on the whole I'm pretty pleased with how it works for me. I thought some people might like to know what I'm using to make it a little easier than simply authoring HTML pages by hand.
The blogging 'platform'
I wanted something simple and lightweight that I could host myself on my website. I've used blogs before on full-blown content management systems which use SQL databases and found them to be more complicated and fragile than they ought to be.
I reviewed some options and settled on Pico CMS. It's a PHP based 'CMS' that uses flat-files for storing content - specifically Markdown files. I've had some success managing and serving content using Markdown in previous projects, and I'm comfortable editing Markdown files directly.
All that is required to run Pico is the PHP code itself which can be downloaded and put on any web host via a file manager or FTP. I simply used my webhost's default cPanel file manager.
The Pico theme I'm using is: 'default-blog', which I've adapted slightly over time to make some amendments to the display of dates and add an RSS feed. The RSS plugin needed tweaking to ensure content was correctly encoded. It took me a while to get round to sorting that, but now people can at least subscribe and receive my writing with none of the complication of the newsletter platform I've used in the past.
How I write and publish a blog post
It starts with me putting some notes down in a note taking app: I use currently use Simplenote for this. It works OK but I'm not particularly wedded to it specifically. However I highly recommend some form of digital note taking app to anyone as an 'life hack' in general.
I do quite a bit of editing and writing within the notes app. Some blog ideas and posts will sit there for a long time and go through multiple iterations before publishing, some go up more or less instantly and some never make it to this blog. I take the writing I do here semi-seriously. I want some of it to be good, but ultimately it's mostly a playground for thoughts, ideas and fun things too.
After writing the majority of the post in the notes app, I use the cPanel file manager on my web hosting account to copy an old blog post file. I then copy the new text from the notes app and paste it into the file and amend the meta data at the top of the file (title, description, date and author) as required. I also make sure the Markdown formatting for things like links and images is OK at this stage.
I don't sandbox new content before publishing: it gets published straight away as it only takes me a few minutes to do this and I doubt anyone minds the odd mistake appearing for a few minutes if indeed they happen to be viewing this at the time.
Once the blog post is live, I do any final editing and tweaks, usually amending inevitable spelling mistakes because my current notes app, nor the cPanel text editor do this for me and the blog post is done.
An evaluation of using Pico CMS
I think Pico paired with an appropriate theme works pretty good and in fact it serves the content for my entire website right now, although there's not much to it so if I didn't have a blog I probably wouldn't have bothered with a CMS at all. The benefits of using it in general I've found are:
- It generates the navigation and the header and footer can be amended easily in one place
- The blog theme creates a nice paginated 'feed' of posts that users can browse through and subscribe to via RSS
- It's relatively easy for me to manage and publish content
- It's not over-engineered
- I can easily extend its functionality if I want to
The only problem with Pico I've found is that it doesn't seem to be widely adopted for blogging and a lot of the plugins and themes are stagnant. I can't see that being a huge problem for me, but it might be for some people.
What I'm planning to change in the future
I've thought about adding commenting, with some fanciful plans for integrating ActivityPub so people can comment via their favourite federated social media platform, or something. But perhaps the least 'elegant' part of the process of blogging on here is copying the content up manually via a web based cPanel file manager.
Commenting and the ActivityPub protocol are interesting, more technically challenging tasks. But also require some thought as to the overall direction of the blog that I haven't decided on - do I actually want to enable commenting? It would be nice to have a conversation with like minded people about things I write. But I already manually cross-post most of my writing on Mastodon. There's also the inevitable spam and content-injection prevention that will be required. Needs a bit more thought that one...
Another area I'm interested in looking at is curating content - whether it be indexing, categorising or tagging content in some way or even making it searchable. I like the idea of a simple way of creating lists of 'bookmarks' under headings. I've been looking at file formats like the browser-based 'netscape' bookmarking format and XBEL. I don't know where that's going yet either so it's on the backburner for now.
Therefore assuming I start with improving my publishing experience first there are two things I will look at next: A slicker way to add the content (Markdown files) directly to the hosting account and a means to draft posts privately so I can preview them before publishing. For the former my searching around bookmarking file formats (XBEL specifically) led me down the path of looking at WebDAV. I even found this implementation of a single file WebDAV server, which I find appealing in no small part due to the serendipity of it being named 'picodav' despite having no relationship as far as I can see to the Pico CMS my blog uses.
However I do it, I'd like a better experience for writing and publishing the posts, perhaps using some third-party authoring client which can easily save directly to the website, as well as nice-to-have features like drafting posts and integrated spell-checking.
In conclusion
So there you have it: that's my how my blog works as it stands and some discussion about how it might change in future. I write this blog mostly for myself, but I know I have a small number of readers who are following along. It also seems to start showing up in web searches so maybe one day my writing might reach a wider audience and might be of some significance to more people too.
In the end though it has been more important to me as a form of expression over the last few years than I perhaps realised when I revamped my website and started blogging again. So whether or not you go down the same route if you are reading this, or perhaps you already have your own blog setup, I hope this post was useful and perhaps inspires more people to get writing (and reading) blogs.