Export list of coding rules from Sonarqube

36k Views Asked by At

I am trying to find a way to get a list of all Sonarqube Java (or whatever) rules (with keys, description, etc.) and export it as an Excel, csv or xml. I get to list them "dynamically" like this, but I would like to have them all in a file. Does anyone know how to do this?

2

There are 2 best solutions below

2
On BEST ANSWER

You can use the /api/rules web service: http://docs.sonarqube.org/pages/viewpage.action?pageId=2392166

1
On

Check this out http://nemo.sonarqube.org/profiles

The initial Profile view just lists all the rules. You can click on the backup link and export the rules to an xml file. This xml file has the rule, the repositoryKey, the key...

I'm not really sure if this is what you want, but hope you find it useful!