Matthew Lang avatar

My /photo page

After reading about Robert Birming’s photo page, I decided to add one to my own blog, with one change. My own photo page turned out pretty well. Here’s what I did.

Adding a new page in Jekyll is straightforward. It’s just a static page after all. Rendering a single photo in Jekyll wasn’t the challenge, though. I wanted to include archives of all the photos I will eventually share on this page, so I needed a way to build an image archive.

Jekyll is a static site generator, so it doesn’t have a database to query for archive photos. I needed another Jekyll-friendly database. Enter the photos.yml file.

This file contains the URLs for each photo’s full-sized and thumbnail versions, the caption, the alt text and the date the photo was taken. Each uploaded photo is added to the top of this file and acts as the source for the photo page and the archive.

I now needed a means to update this. I have my own publishing app, Postpress, that updates my Jekyll site. It’s a Rails application that lets me publish articles, upload images, and manage a few other data collections on my website. I already could upload images for my posts, so the photo upload uses the same process but saves to a separate photos folder.

I then collect the uploaded photo URLs, caption, date and LLM-generated alt text (which I always review), and add these to the top of the photos.yml file on my blog. Postpress commits these changes and pushes them back to my source code management host, where a new build of the website is triggered.

The resulting photos.yml file will look something like this:

---
- url: https://notarealhost.com/photos/2026/10/golf-course-full.jpg
  thumbnail: https://notarealhost.com/photos/2026/10/golf-course-thumb.jpg
  alt: A golf course putting green with a white flag pin, lush fairway, scattered trees, and a partly cloudy blue sky.
  caption: "Another view of the golf course. I wish I was more organised. I would have brought my clubs and played."
  date: 2026-10-10
- url: https://notarealhost.com/photos/2026/10/nuphy-keyboard-full.jpg
  thumbnail: https://notarealhost.com/photos/2026/10/nuphy-keyboard-thumb.jpg
  alt: Close-up of a mechanical keyboard's upper-right corner featuring dark gray, white, and teal keycaps with an RGB light strip.
  caption: I switched back to the original keycaps on my Nuphy Air75 keyboard. I quite like the default keycaps.
  date: 2026-10-09

I have a handful of layouts and views, plus a plugin that aggregates all the data for the photo pages, letting you drill down into the archives by year and navigate back. As the photos.yml is located in the _data folder in Jekyll, I can reference these photos by using site.data.photos.

A photo archive page from 2026 showing two thumbnail images: a golf course on October 10 and a mechanical keyboard on October 9.

Here are the files I needed to build this.

  • photo.md - The photo page itself, which will grab the first photo from the site.data.photos collection.
  • photo/archive.html - The archive page showing a photo for each year I have posted.
  • photo-year.html - The page that displays all the photos for a year.
  • photo_archive.rb - A plugin that generates a page for each year.

This took a bit of time today, but it was time well spent. I like to think of this as my own personal Instagram baked into my blog, without the hassle of actually having to post to Instagram.

I am really intrigued by Enkihost, a new host for Ruby applications by Albert Oliva. Pricing seems very competitive, but I haven’t run an application there yet, let alone five. It’s certainly cheaper than my current DigitalOcean and Hatchbox setup.

It turned out to be a pretty good day for Drew’s coaching at Castle Park Golf Club today. Sunny, but also quite windy.

Golf course green with red flag, lined by autumn-colored trees and rolling green hills under a partly cloudy sky.

Starting a week off work tomorrow to take Drew to an all-day golf coaching session at Castle Park Golf Club. I’ll be pitching up in the clubhouse all day. Expect a few posts tomorrow, and maybe a few blog changes.

I updated Firefox to the new design today, and it’s nice to see it looking modern once again. I’m also glad to see Compact Mode is back, now with an auto option for smaller screens.

Every morning is the same. I close tabs for pull requests I reviewed yesterday and check which ones have been merged.

GitHub’s favicon shows a green tick for a pull request ready to merge, but it would be nice if it updated to a purple indicator when a pull request is already merged.

Alice Girard Guittard reminds us of the intentional internet and why it’s better for us.

You didn’t really have one big app that you could open and order it to entertain you. Instead, you had a few dozen of bookmarks to websites, each with a specific idea in mind. A site for video game news, that one website with lots of tutorials, a blog about anime that didn’t update often enough, a wiki about a TV show from the 90s…

— Attention is all you have by Alice Girard Guittard

A reminder that it’s still there. You just have to go looking for it.

Laurel: a weekend Hanami project

Over the weekend, I wanted to build something with Hanami. I wanted to build something with Hanami more as a learning exercise than anything else. I had a bookmark manager written in Rails that has been languishing on the side, so I thought I would build something a bit more functional using Hanami. I called it Laurel.

Bookmarks usually build up for me. I wanted to build a way to resurface bookmarks so they can be acted on. It’s something I didn’t have in the previous bookmark application. I also didn’t want to be distracted by using background processing. Any methods that calculate ranks or anything else like that will be handled during the request.

This isn’t my first Hanami project. I built a couple of smaller applications a couple of years ago, but I never kept them because they were just a way to see what Hanami can do.

Getting the project started was familiar. Typing bundle exec hanami new is almost the same as kicking off a new Rails project. Once I had a blank application set up, I started looking into the code. It has similarities to Rails, but also differences.

I’m not going to delve into the experience of using Hanami or compare it to Rails, but I enjoyed using it, and the developer experience is good.

As for the project’s goal, I eventually finished it on Sunday night. It includes the following features:

  • Capture: add/edit, tag, import
  • Curate: the digest page, Elo comparisons, evergreen marking, archiving, snoozing or ignoring bookmarks
  • Decay: the HN-style ranking score

Bookmark digest interface showing a priority comparison between two articles and a list of saved bookmarks with action buttons.

The digest page is the real workhorse of the application. Here you can decide which of the two bookmarks is more important and also action other bookmarks that appear on this page. Being able to action bookmarks over time with the archive, snooze or ignore buttons is more helpful to me and actively curates the collection.

The difficult part was deploying the application to Hatchbox. I originally had an error in the application that appeared only in the production environment, not the development environment. I eventually resolved this issue, but I still seem to have a deployment issue: it requires a restart after deployment, and I’m sure this is a mistake on my part when setting up the application.

I’m going to definitely keep using this, and over the next few weekends, I’ll be adding more features and hopefully resolving that deployment issue on Hatchbox as well.