by David Bryan Copeland

Working on Ruby on Rails apps can be a joyful experience. As application get larger, it is often the case that productivity nose-dives and it becomes harder to ship new features or change existing behavior. It doesn’t have to be. This book focuses on opinionated strategies to keep Rails applications maintainable.

The overarching theme is that keeping things maintainable means investing in keeping them that way every day: Agreeing with team members on standards and sticking to them. Automate when possible. Make it easy to know the “right” way to add new code. Avoid surprising or magic behavior. I think of this as resisting entropy.

The book goes into a lot of details: Application setup, and bin/ scripts, where to put the business logic, routing, HTML templates, helpers, css, javascript, models, database, controllers, jobs, and more. Throughout, the example show the recommended code and how to test it.

Of course, I don’t agree with every single piece of advise that Copeland makes. Every engineer develops their own scars based on their past experiences, and try to protect against different future pain. Sometimes there are trade-offs, and reasonable people can disagree on what to optimize for.

Overall, I got a lot of ideas on how to improve maintainability of the apps I am currently working on, and expect that most folks would too.

Links: