Stripe Engineering · Fable Tales & Anna Mason · April 28, 2026
The story is older than the post — rubyfmt has been a side‑of‑desk Stripe project for years — but the rollout writeup is the part worth reading. Stripe runs the world's largest known Ruby codebase (somewhere between 25 and 42 million lines, depending on how you count generated code) and for most of that history, the codebase was un‑formatted: every team's local style, every pile of legacy whitespace, every strangely‑indented if‑else preserved in amber. The Developer Productivity team's job was to flip it to a single canonical shape without breaking history, blame, or anyone's open PR.
They picked rubyfmt — Rust‑based, zero‑config, fast enough to run inline in editors — and the technical anchor of the writeup is how they validated correctness at this scale. Rather than diff strings, they built ripper‑tree diffing: parse both before and after into Ruby's native AST, normalize trivia, and assert structural equivalence. That's the only way to bulk‑format tens of millions of lines and not introduce a single subtle behavioural regression. It also gave them a clean opt‑in path: teams that wanted formatting could turn it on, the diffs were guaranteed semantics‑preserving, and CI could run rubyfmt in milliseconds against any new PR.
On a single Saturday morning, 62,213 files were re‑formatted. Today, 100% of Stripe's Ruby is canonical.
The cultural detail is what makes the piece more than a tooling postmortem. Stripe didn't mandate the cutover. They opt‑in‑rolled rubyfmt across teams, kept the AST‑equivalence guarantee load‑bearing, and only mass‑formatted the long tail when the social proof had built up enough that almost nobody was going to push back. That's the part most "we standardized X" engineering writeups skip — that the format change is the easy bit, and the real work is making thousands of engineers shrug rather than argue when their muscle memory stops matching the file on disk.
Why it matters for senior eng readers: this is the platonic case study of a long‑running developer‑productivity bet — Rust where Rust earned its keep, AST‑equivalence as the testing strategy that made the migration safe, and a rollout patient enough to land without a revolt. Pair it with the Cloudflare Workflows v2 piece from April 15 (which solved a similar Durable‑Object‑bottleneck problem by sharding load across new SousChef and Gatekeeper components) and you have a picture of how 2026 platform teams actually move: Rust for the hot path, structural verification for the migration, slow social rollout for the humans.
Read the full Stripe writeup →