Standardizing 25 Million Lines How Stripe Unified the World Largest Ruby Codebase.
Inside Stripe Massive Ruby Migration: Formatting 25 Million Lines of Code with Rust In 2024, engineers Fable Tales and Anna Mason from Stripe embarked on a monumental task: standardizing the formatting of what is likely the world's largest Ruby codebase. Spanning over 62,213 files and 25 million lines of code , the repository lacked a unified style, leading to inconsistent "handwriting" across their global engineering team. The Failure of Traditional Tools Stripe’s journey toward a unified format was riddled with obstacles. Their previous attempt using prettier-ruby failed due to performance bottlenecks; the tool was too slow for a codebase of this magnitude, and extra-large files often caused it to crash. Meanwhile, RuboCop , while excellent for linting, proved insufficient as a primary formatter due to its complex configuration, which often led to inconsistent setups among different developers. The Solution: rubyfmt and the Power of Rust The team pivoted to rubyfm...