Highly recommended
Subtitled ‘A Personal Exercise in Empirical Software Design’, Tidy First? is written by Kent Beck, best known for the creation of the Extreme Programming development method. It is a short book, made up of 33 short chapters, that explores the question ‘Should we tidy our code before adding a new feature?’ This is ultimately left for the reader to decide, based on context, hence the question mark in the title.
The chapters are grouped into three parts. The first part explains what Kent means by ‘tidying’: tiny refactorings that are easily reversible. The chapters in this part each detail one such tidying: what it is, and when you may choose to use it. The second part is on ‘managing’ tidying: separating tidyings from other changes, batching tidyings, and crucially when to tidy your code. The final part is ‘theory’: why do we tidy code? This covers such well-worn concepts as coupling and cohesion, as well as bringing in concepts from economics such as Options, and the Time Value of Money.
This is a very easy to read book. For people familiar with Kent’s work, and Agile development in general, there’s potentially nothing new here, but it does offer clear explanations of the concepts it explores. Certainly it gives lots of fodder for senior developers and consultants to expand on the classic ‘it depends’ answer to development questions: Kent’s explanations highlight the forces around tidying that help you choose why you should or shouldn’t tidy in a given context.
Website: https://www.oreilly.com/library/view/tidy-first/9781098151232/