Ruby, my magic toolbox

24 June 2024

Every few years someone declares Ruby dead, and every few years I open an editor, type a few lines, and remember why it is still the first tool I reach for. Ruby was designed to make programmers happy, and after all this time that design goal still pays off in my day-to-day work.

What keeps it in my toolbox is how little ceremony stands between an idea and a working program. A thought like “take these records, group them by month, and sum the totals” reads almost the same in Ruby as it does in English. Blocks, map, each_with_object and the rest of Enumerable let me describe what I want without drowning in how to get it. The code stays close to the problem.

Then there is the ecosystem. Rails is still one of the fastest ways to take a product from nothing to deployed, and the surrounding gems — Sidekiq, RSpec, Sequel, Roda — are battle-tested and a pleasure to use. For everything else, Ruby is the quiet workhorse of automation: a quick script to rename a thousand files, parse a log, or glue two APIs together is often faster to write than the shell command it replaces.

Is it the fastest language? No, and it does not pretend to be. But raw speed is rarely my bottleneck — my time is. Ruby optimises for the scarce resource: the human writing and reading the code six months later. When throughput truly matters I reach elsewhere, but that is the exception, not the rule.

So Ruby stays my magic toolbox not out of nostalgia, but because it consistently turns vague intentions into running software with the least friction I have found anywhere. That is a kind of magic I am happy to keep using.

Return to the blog for more.

← Back to blog