Skip to content

Commit

Permalink
[blog] updates on currently reading (#200)
Browse files Browse the repository at this point in the history
  • Loading branch information
riastrad authored Nov 26, 2024
1 parent 4954e35 commit 0568930
Show file tree
Hide file tree
Showing 3 changed files with 29 additions and 0 deletions.
1 change: 1 addition & 0 deletions bin/technical-dictionary.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
Node.js
dirge.png
the-jokers.png
pret-1.png
Expand Down
2 changes: 2 additions & 0 deletions posts/2022/currently-reading.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,8 @@ tags:
permalink: /notes/{{ page.date | dateYear }}/{{ title | slugify }}/index.html
---

> **Editor's Note:** As of November 2024, this blog no longer reflects the reality of how the site's "currently reading" feature works. If you're curious about the *how*, you can skim [this pull request](https://github.com/riastrad/cyberbspace/pull/195). If you're curious about the *why*, you can read [this blog post](/notes/2024/dropping-the-ocean).
## What is this about?

A couple weeks ago, on a lark, I decided to see if I could have the main landing page of this website dynamically update to reflect whatever book I'm currently reading.
Expand Down
26 changes: 26 additions & 0 deletions posts/2024/faster-reading.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
---
layout: post.njk
title: Dropping the Ocean
summary: Brief log of changes to my home page's currently reading feature
date: 2024-11-26 19:00:00
tags:
- post
- development
- web
- brief
permalink: /notes/{{ page.date | dateYear }}/{{ title | slugify }}/index.html
---

I have been frustrated with having to pay Digital Ocean $5.30 every month just because I wanted to show what books I was reading on my site's home page. Last week, I [finally did something](https://github.com/riastrad/cyberbspace/pull/195) about it.

The reason I didn't do this sooner, was because I have had [grand plans](https://github.com/riastrad/cyberbspace/issues/30) to completely re-vamp how I manage my digital reading record. I started down this path & quickly got bogged down in the details of book editions, date formats, ISBN numbers, &c. It all started to feel a bit silly & messy, so I set aside.

Back in 2022 I was steeped in backend engineering. It felt easy and natural to spin up a Node.js server to connect my site to my reading data. Now that I'm no longer surrounded by on-call schedules and availability metrics, I had the epiphany that the feature doesn't need to be up-to-the-minute or highly available. I'm not changing the books I'm currently reading that often. I was being a computational wastrel.

So I've changed my approach. I've now got a GitHub action that runs once every 4 hours to check my reading app's RSS feed. If it's changed compared to data that was previously pulled down, the action updates the data, commits it to my repo, & triggers a fresh site build. You can see the details in the [pull request](https://github.com/riastrad/cyberbspace/pull/195). I like this approach, it gets me closer to where I want to be[^1] without forcing me to spend hours build out a bespoke system. It feels more conducive to iteration, which I've found leads to better outcomes. I already see how I can use this strategy to catalog the books I have read & auto-generate dedicated review pages. I can do this piece by piece until I'm ready to swap out my use of [Oku](https://oku.club) for my own backend. Even better, my book data is now backed up in my site's git history.

My only hesitation about going further down this route is the fact that I won't be able to easily pull my review data from Oku. They hide it behind a series of API calls that I will have to reverse engineer. For now, though, I'm happy that these books & links load instantaneously with the page instead of there being a perceptible delay while the front-end waits to hear back from the back-end.

There's also a small hint of irony about this work. I'm not currently drawing a regular salary from anywhere, so being mindful of expenses is a more prominent part of my life. With the $63.60 I have saved by making this change, I have found the exact justification I needed to go out and buy a few more books.

[^1]: i.e. managing my reading data myself & baking all of my data into my site directly

0 comments on commit 0568930

Please sign in to comment.