Ramblings of an aging IT geek
← Ramblings of an aging IT geek
rust

the one-liner that talked me out of rust

A quick counterpoint to my own Rust enthusiasm, where a five-minute shell pipeline did the job and a binary would have been overkill.

A terminal with code on screen

Having spent the morning singing Rust's praises for a small tool, I owe it a counterpoint by lunchtime, because an hour later I caught myself about to do exactly the wrong thing.

I needed to find which of a few hundred files were larger than a megabyte and hadn't been touched in a year. My first instinct, fresh off the previous build, was cargo new. I actually typed it.

Then I stopped, deleted the directory, and wrote this:

find . -type f -size +1M -mtime +365

Done. No build, no binary, no afternoon. find has done this for forty years and it isn't about to get it wrong.

The point of the earlier post wasn't "Rust for everything". It was "Rust for the things you keep". This was a thing I needed once, the answer was the output, and there was nothing to keep. Reaching for a compiler here would have been vanity, not engineering. The right tool was the one already on the box.