Pomodoros and leverage ratios

I love pomodoros 🍅. But I have to admit, most of the time when I reach for them, it’s because I"m already having trouble staying on task with whatever I’m doing. I generally don’t get a lot of value out of the ’longer break’ option, a steady beat of work and breaks is enough for me. In those circumstances I often find solace in the idea that a well-constructed pomodoro creates a certain lower bound on my work-to-play leverage ratio. The classic 25 minutes on, 5 minutes off gives you a 5:1 ratio. ...

November 27, 2023

One problem with user-scoped `systemd` timers

I’ve discovered one big downside of [putting systemd times into ~/.config/systemd/user/][1]: They stop running when you log out. Two ways around this problem: Bite the bullet, and install the timers into /etc/systemd/. This means giving up chezmoi version control, making the overall system more snowflake-y. I’m not crazy about it. Remote in with tmux, instead of ever logging out, just use C-b d to detach from the session. I’m going with #2. The lead developer of ktty is known not to like tmux, so there’s probably a way to detach long-running SSH sections inside of kitty itself – but I haven’t found it yet. Have you?

November 26, 2023

Promoting Blog Tag Reuse with `fzf`

Some more updates to the main repo of this TIL site today, in particular I have added a new fzf-tags.fish script. til uses this script to Scrapes all the YAML tags: frontmatter from all current Markdown posts, Puts me into a multi-select fzf menu containing them, and Puts anything I select into the tags: of the new blog post. Tags form natural breadcrumb trails throughout a blog as it grows organically over time. Many an afternoon have I spent reading one or two particular tags of interest from a prolific blog. But, if you don’t remember to reuse the tags in the first place, you’ll never build the trail in the first place.

November 25, 2023

The Rule of Four

A communication heuristic, optimized for asynchronous communication of detailed concepts between human beings. Not really a TIL, I’ve been sitting on this one for a while. Rationale Existence “proof” Our short term memory can hold at best about 7 +/- 2 chunks of information at a time. Start with the lower end of that: 5 chunks. Assume that whatever someone is “really” trying to do takes up 1 of those 5. We’re left with 4 chunks. Conclusion Organize your work processes as much as possible so that they can be effectively understood using at most 4 chunks of short-term memory. If you feel a process is too complicated to be held like that, find conceptual fault lines to hack against until it’s true. ...

November 24, 2023

Hugo's Secret RSS Feeds

This blog now has a swanky new RSS feed button right on the front page, courtesy of the well-designed PaperMod theme powering things on the backend. Hugo newbies often don’t know that Hugo usually generates these RSS feeds automatically for new websites. You usually have to go out of your way to turn them off. Example: https://andrew-quinn.me/index.xml exists, and has existed for quite some time, without me needing to lift a finger (although I might want to put a button on my home site too!).

November 23, 2023

Hosting on Azure? Don't forget to declare UTF-8

For a long time after moving my website from Netlify to Azure, none of my fancy emoji or weird umlaut characters would display properly. Today I fixed that by popping back into the the Hugo theme I built off of minimum-viable-hugo and adding 1 <meta charset="utf-8"> to themes/minimum-viable-hugo/layouts/index.html and themes/minimum-viable-hugo/layouts/partial/head.html. (There’s probably a way to intimidate Azure Static Web Apps into using UTF-8 by default too, but I didn’t bother to look.) ...

November 22, 2023

Git controlled, user-scoped, recoverable-after-install `systemd` services and timers

TL;DR systemd timers are a serious upgrade from cron. Accept no substitutes. ~/.config/systemd/user lets you run user-scoped timers and services, in a place where you can version control them with Git easily, and even keep a handy backup with chezmoi! Story We had the great honor of having our friend Tri Phung (LinkedIn, GitHub) over for dinner yesterday. As is often the case the conversation turned to work. I’ve been on a kick of using Github Actions remotely and shell scripts + systemd services/timers locally to sketch out some ideas for new websites in Hugo. ...

November 21, 2023

That damned Debian 10 one-liner I always need to let me `sudo`

1 2 # ⚠️: Reboots your VM. su -c "$(whereis adduser | awk '{print $2}') $(whoami) sudo && $(whereis reboot | awk '{print $2}')" In all its glory! For Debian 10 and up, because Debian 10 is where the sysv to systemd conversion became totalizing. Let’s break down quickly why each part of this is needed: Since we are trying to add ourselves to the sudo group right now, we obviously can’t use sudo. Enter su -c to switch to root, run a command, and then switch back out. whereis adduser instead of simply adduser because adduser is no longer in the $PATH by default anymore. Tempted to try which adduser? No dice – which only gets you things in the $PATH as well: 1 2 3 andrew@debian-10:~$ which adduser # zip, zilch, nada. andrew@debian-10:~$ whereis adduser adduser: /usr/sbin/adduser /etc/adduser.conf /usr/share/adduser /usr/share/man/man8/adduser.8.gz awk to rip out /usr/sbin/adduser, which - thankfully - at least is still executable. $(whoami) because your name might not be andrew! whereis reboot because I don’t want to have to manually remember to logout and login again.

November 20, 2023

Art of the dotflag -- `.nojekyll`, `.gitkeep` and their ilk

This weekend I’ve been procrastinating playing the long game by getting some nice workflows set up for my TIL content repository and its associated website (cf Context, below). If all goes well, by the time I hit :wq on this TIL, it should invisibly trigger 2 Git commits, a Hugo build, and then appear on the site fully-birthed. One of the more interesting patterns I noticed was the .nojekyll empty file which I had to build to get GH Pages to stop tussling with my Hugo Action for turf. .nojekyll is technically a dotfile, but it doesn’t actually contain any content - its mere existence is enough to change behavior. And that makes their existence a really interesting design affordance offered to us developers by the filesystems we use every day but rarely think about. ...

November 19, 2023

A good place to symlink local builds

I’ve been a big fan of both spaced repetition in general and the Anki spaced repetition system in particular for a long time now. So today, after a fresh new install and blinging out of Ubuntu 23.10, I decided to take the next step, as I often do with programs I use a lot, and try to build and compile it myself. This turned out to be pretty easy! The docs warn that ./run is slower than the non-optimized build, but I don’t notice much of a difference on my machine. It did however leave me with the question: Where should I put the anki symlink to ./run? ...

November 18, 2023