robert-c-martin's most widely read book, published in 2008, presenting principles and practices for writing clean, readable, maintainable code. Despite the subtitle's reference to "Agile Software Craftsmanship," the book sits at the intersection of the Agile movement and the broader software craft tradition, emphasizing technical excellence as the foundation for sustainable Agile practice.
Content
The book is structured in three parts: principles, heuristics, and case studies. Part one covers naming conventions, function design (small functions, single responsibility), comment philosophy (code should be self-documenting), formatting, objects and data structures, error handling, and boundaries. Part two provides a catalogue of code smells and heuristics. Part three works through extended refactoring examples applying the principles.
Key themes:
Relationship to Agile
robert-c-martin was a manifesto signatory at snowbird-meeting-2001 and one of the strongest voices for technical excellence in the Agile community. His concern — shared with ron-jeffries, martin-fowler, and other XP-tradition signatories — was that the Agile movement was being adopted in ways that emphasized process (especially scrum) while neglecting technical practices.
Clean code is the technical foundation that makes refactoring, continuous-integration, and test-driven-development possible. Without it, technical-debt accumulates and teams lose the ability to responding-to-change that the agile-manifesto promises. robert-c-martin framed software craftsmanship explicitly as the technical prerequisite for Agile's organizational promises.
Reception and controversy
The book became a standard text in software development education and corporate training programs. It has also attracted criticism: the code examples use Java and reflect a particular (some argue dated) OO style; some readers find the prescriptions too rigid; and the framing around "professionalism" has been criticized as excluding and shaming.
robert-c-martin's subsequent personal controversies (unrelated to the book's content) have complicated its reception in the community, though the book remains widely used.