Disable rule in sonar

In web interface for particular rule just press Deactivate button:

enter image description here


You have to remove this rule in the quality profile that you are using to analyse your project.

Please refer to the documentation that describes all this: Quality Profiles in Sonar.


The right way to do is to put something like this on sonar-project.properties file per project:

sonar.issue.ignore.multicriteria=e1,e2
# tab characters should not be used
sonar.issue.ignore.multicriteria.e1.ruleKey=squid:S00105
sonar.issue.ignore.multicriteria.e1.resourceKey=**/*.java
# right curly braces should be on a new line
sonar.issue.ignore.multicriteria.e2.ruleKey=squid:RightCurlyBraceStartLineCheck
sonar.issue.ignore.multicriteria.e2.resourceKey=**/*.java