Usage
Generate a Meterian JSON report with
Through the Meterian scanner of choice generate a JSON report for your sonar project by launching a scan in the source code folder.
Thin client scanner example
$ java -Dcli.param.report.tree.included=true -jar /tmp/meterian-cli.jar --report-json=report.json
Dockerized client scanner example
$ meterian-docker --report-json=report.json --flags:cli.param.report.tree.included=true
Import the Meterian findings in SonarQube
To import the Meterian findings in SonarQube, analyze your project via a SonarScanner that is suitable to your it (SonarQube provides a set of scanners dedicated to specific programming languages). The example below uses the generic scanner (suitable for scanning JS, TS, Go, Python, PHP and more).
$ sonar-scanner -Dsonar.login=YOUR_TOKEN \
-Dsonar.projectKey=PROJECT_UNIQUE_KEY \
-Dsonar.meterian.reportJsonPath=PATH_TO_REPORT \
-Dsonar.sources=.
You source code will be analysed and findings from SonarQube and Meterian will then be uploaded to your SonarQube instance.
These findings will be visible on the web interface as issues:
Last updated
Was this helpful?