A talk I really enjoyed at Rails Conf 2007 was Clean Code by Robert Martin. An important idea from that talk was “Always check in your code a little bit cleaner than when you checked it out”. I never looked at refactoring as being that simple, but it is. Prior to this talk, I looked at refactoring as this big undertaking. I mean the whole application can use some improvement, right? I also tended to take on big refactoring endeavors by deleting the current code and starting over. Robert Martin urges against this, since you might break the current application with the rework code, and that’s much worse than ugly code. At least the ugly code is working. Tackling the smaller refactors, by improving the code a little bit at a time, the refactoring process becomes manageable.