[Codenarc-user] CodeNarc - Philosophy of the Basic Ruleset
Brought to you by:
chrismair
From: Chris M. <chr...@ea...> - 2010-10-30 12:39:50
|
Hamlet (and anybody else), In many ways, I patterned CodeNarc after PMD. That included creating a "basic" ruleset. The intent was that these were "standard" rules that everyone could agree on. That is typically the first ruleset that people turn on, and no one would argue that the violations need to be fixed. I may have strayed a bit from that intent when I added the Unnecessary*Rules (e.g. UnnecessaryBooleanExpressionRule, UnnecessaryIfStatementRule, etc.), or perhaps other rules in the basic ruleset.. When I first started this project, I knew that categorization of rules would be challenging sometimes. A few days ago, I attended a presentation/discussion of the Sonar tool at my company. We were discussing PMD and Checkstyle, and a couple people indicated that even the PMD "basic" ruleset is somewhat subjective, in terms of being universal or not. Several people (including me) agreed that using tools like this eventually requires customization of the chosen rule set, since there really can't be a one-size-fits-all. All that being said... I am ok continuing with what we have, and leaving the current rules where they are. But if anyone has strong opinions about a better categorization, it would be better to consider reorganizing now rather than later. Thanks. Chris |