“Code cleanup” is a phrase that sounds like it’s a lot of work. Well, sometimes it may be an arduous task, indeed. But that doesn’t mean it’s the way it should be. As with many things in software development—and in general life—it’s often more comfortable, less painful and more productive to do an unpleasant task every day, little by little than let it accumulate and become a monster.
That’s what today’s post is about. We’ll present seven simple code cleanup tasks that you can perform daily, to keep your codebase readable, easy to navigate, and maintain. We don’t necessarily expect you to perform all of the steps every day. On some days, you might be able to pull it off, but on others, it might be harder to do so.
Think of the seven tips you’ll read as a practical embodiment of the scouting principle: leave the code better than how you’ve found it. Let’s get started.