|
Simon, can't we imagine to define a boolean option on Sonar Chectyle Plugin to handle this feature ? To my mind, if it's not complicated to implement, it should be added as quick as possible. In Sonar 1.9, we'll handle only the default behavior by adding the following line in the checkstyle configuration file <module name="SuppressionCommentFilter"/>
So rules violations between a comment containing CHECKSTYLE:OFF and a comment containing CHECKSTYLE:ON will be ignore : //CHECKSTYLE:OFF int toto = tata; toto.myCheckstyleError(); //CHECKSTYLE:ON |
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
What a shame that checkstyle does not manage the standard way used by PMD. This is a recurrent need wanted for sonar (see
SONAR-208). We keep it actively in mind for next releases.