Ramblings of an aging IT geek
← Ramblings of an aging IT geek
tooling

the dotfiles repo i should have made years ago

Moving years of scattered shell and editor config into a single git repo with stow, and why bare-repo cleverness lost to something boring.

A keyboard lit by a terminal

I finally put my dotfiles in a git repo. It only took about a decade of copying .vimrc between machines by hand and forgetting which one had the good tweaks.

The thing that had stopped me was overthinking it. Every time I looked, someone had a clever bare-repo setup aliased to dotfiles status, or a bespoke install script that did things I didn't fully trust. I tried the bare-repo trick once and spent twenty minutes confused about why git status in my home directory was suddenly listing every file I own. Clever, but not for me.

In the end I used stow. A plain repo, one directory per program, and stow vim drops the symlinks where they belong. To set up a new box I clone the repo and run stow a few times. That's it. No magic, nothing to remember, and if it breaks I can see exactly which symlink points where.

The unexpected payoff was the diff history. I can now see when I added a given alias and, more usefully, why I removed the half-clever ones that kept biting me. My config used to be an accumulation of mystery. Now it's a thing I can read. I should have done it years ago, but the boring version was always the one worth doing.