imgup v3

· 2 min read · 329 words

A few years ago I wrote a thing called imgup. It was a super simple Sinatra app that let me upload images to SmugMug and get a snippet back for pasting into a blog. Then last year I let Claude reimagine it into a go CLI tool, which didn’t work so well in the end.

Yesterday I let Claude redo it again, with more guidance and planning from me, going back to my original Sinatra codebase but rewriting in Typescript so I can run it in a Cloudflare worker instead of my Synology.

This time around it’s a genuine improvement: I can use copy/paste keyboard shortcuts (so if an image is in Apple Photos I can just ⌘c and ⌘v it into the web page), and I get a real PWA. Moving it into Cloudflare let me more easily put it behind Cloudflare Zero Trust, so I get better auth than basic http.

The workflow for the overhaul involved several passes:

The first pass was “let’s get this into a state where I can put it on a worker.” I just wanted to make sure I had what I had previously. I used superpowers for that session and it got me into a “just works” state with no false starts.

The second pass was an impeccable pass that was pretty harsh about my original design, rightly pointing out that I’d just grabbed [tiny.css][] off the shelf to make a fire-and-forget “just wrap a working shell script in routes” Sinatra thing. That pass netted me a cleaner redesign, and some small quality of life improvements.

I did get briefly bogged down. Between all the context eaten up by the superpowers session and impeccable pass, I was sitting at about 45% context window consumed, and Claude got sorta dumb on me about a theme switcher.

This morning I did another impeccable pass, and that got me some incremental refinements and the suggestion to have a copy/paste option.

The impeccable passes also helped me think through some accessibility stuff. The original imgup solved some problems the wrong way, and left some things off the table I shouldn’t have. Getting prompted about the sloppy semantics of the original version caused me to go look at my blog design and realize how much I’d left uncooked.

A web page for uploading images to SmugMug
imgup v3 redesign