So people have a lot of ideas about how software should be written; how code should look; what should be tested; and just about everything else.
We also know we can measure most of these things, cyclomatic complexity, code coverage, method length, methods per interface, and just about anything else. As we are talking about code we know that we can measure most of this, fxcop, and many source code visualization tools are out there.
These tools sometimes are also used in reference to automated build tools.
But they don’t yet seem to make it into to the IDE at the point of check in.
What would be the effect if a developer had a small message that popped up upon check-in that gave a score for the changes that they were about to commit. What would happen if there was a leader board? How would a code base change, and how fast would it happen?
There are some important questions to answer before you turn this on in a company. First and foremost make sure that you award things you actually want to see. And lastly, never underestimate the ability of people to game a system; they will find the loophole and they will crawl through it and they will likely get upset if you tell them that what did was against the spirit of the game.
So maybe this isn’t a good idea, but it is still interesting to muse on the concept.