A grimoirelab-perceval backend for the API of a Sonarqube service [1] that extracts information about the projects hosted in such service. It is basic backend of grimoirelab-perceval [2], the data collector of CHAOSS GrimoireLab Tool.
This backend needs perceval installed.
Then fine tune and run sudo ./INSTALL.sh
.
The executable expects the configuration file perceval/backends/sonarqube/sonarqube.cfg to be on the same directory. It accepts the following (sections and) parameters:
[connection]
- SSL_VERIFY accepts True/False, Y/N, Yes/No.
- API_TOKEN is a user token for the SonarQube API.
[sonarqube]
- TARGET_METRIC_FIELDS is a list of Sonarqube metric names sepparated by commas.
The executable expects the configuration file perceval/backends/sonarqube/sonarqube.cfg to be on the same directory. It accepts the following (sections and) parameters:
[connection]
- SSL_VERIFY accepts True/False, Y/N, Yes/No.
- API_TOKEN is a user token for the SonarQube API.
[sonarqube]
- TARGET_METRIC_FIELDS is a list of Sonarqube metric names sepparated by commas.
Once correctly deployed this backend is used like any other. perceval sonarqube --help
shows the corresponding help, with the list of available categories for Sonarqube.
Ignore the archive-related arguments. Archiving isn't yet implemented. --from-date
isn't implented yet either.
Please check TESTING.md for more details. For a fast track introduction:
- install httpretty:
$ sudo pip install httpretty
- run all enabled tests:
$ python3 tests/test_sonarqube.py