Don’t leave broken windows (bad designs, wrong decisions, or poor code) unrepaired. Fix each one as soon as it is discovered. If there is insufficient time to fix it properly, then board it up. Perhaps you can comment out the offending code, or display a “Not Implemented” message, or substitute dummy data instead. Take some action to prevent further damage to show that you’re on top of the situation.

— The Pragmatic Programmer: From Journeyman to Master

I can’t reiterate this more.

Every time I see a pixel off, a indentation wrong, a word mispelt, I just correct it. I couldn’t just watch things continue to be wrong when I know I can fix it.

And once everything looks tidied, your peers do want to make a positive contribution too. And hopefully, just hopefully, they perform a similar level of upkeep after a while.

The broken windows theory is a criminological theory of the norm-setting and signaling effect of urban disorder and vandalism on additional crime and anti-social behavior. The theory states that maintaining and monitoring urban environments in a well-ordered condition may stop furthervandalism and escalation into more serious crime.

— Wikipedia

Singapore hires a lot of cleaners to sweep up our road sides. It’s quite the same idea, the theory is that once there is litter, people would mind lesser adding more litter to the roads.

And therefore, if you want clean code to look at, why not start with yourself.

comments powered by Disqus