Reputation: 2623
I am using SonarQube 7.9.1. I have Quality Profile containing ~450 active rules for Java code. There are exporters for FindBugs, PMD and Checkstyle in SonarQube, but they are not exporting all available rules. After export ~20 rules are missing. What can be the cause of that?
Example of missing rule: "Unnecessary imports should be removed". It seems strange, because both Checkstyle and PMD have such rule available.
Is it possible to export all rules defined in SonarQube Quality Profile to Checkstyle, PMD and SpotBugs rule files?
Upvotes: 3
Views: 1044
Reputation: 9126
I'm guessing, that you enabled SonarQube rule RSPEC-1128 Unnecessary imports should be removed and now you want to have enabled UnusedImportsCheck in Checkstyle ruleset file. I don't think the exporter works in this way. It just takes all enabled rules of a specified tool and export them in a file. It means that if you enable UnusedImportsCheck Checktyle rule, I'm sure it will be in the exported file.
Is it possible to export all rules defined in SonarQube Quality Profile to Checkstyle, PMD and SpotBugs rule files?
It is possible to export:
It is impossible to export SonarQube rules as different tool rules, example:
Upvotes: 2