Hacker News new | ask | show | jobs
by taylodl 686 days ago
When you say, 'subpar code', what do you mean? How are you measuring the quality of the codebase? Is it objective? Can a tool be run that will spit out a number and below a certain number the code can be deemed 'subpar'?
1 comments

When you see many of functions with 500 - 1000 lines or most of functions with 10-15 if else statements, I am not joking... There lots of and lots of FIXME: bla bla. If you see this what would you think ?
Point taken.

Do tools such as Crap4j exist for other platforms? It measures the amount of CRAP (Change Risk Analysis and Predictions) in your code. Cyclomatic complexity is one of its big measures for determining CRAP. What's nice about having a tool is there are no arguments. The first step on a pull request is determining whether the code is CRAP!

Most organizations quickly outgrow the need for such a tool, but yours might be one that would benefit. You'd be amazed at how objective social pressure works on a dev team, though beware, you may have problems if your team's Primadona consistently produces CRAP code!

Edit: Link to Crap4j - http://www.crap4j.org/

We just heard about it, thanks for the comments.