I am trying to add SonarQube analysis to our OSS Project with travis on Github.
I performed the following steps:
.travis.ymlsonar-project.properties file feature/sonarcloudThe final result can be seen here: https://github.com/open62541/open62541/tree/feature/sonarcloud
Unfortunately Travis does not submit the sonar analysis:
INFO: Scanner configuration file:
/home/travis/.sonarscanner/sonar-scanner-2.8/conf/sonar-scanner.properties
INFO: Project root configuration file: NONE
INFO: SonarQube Scanner analysis skipped
(See also https://travis-ci.org/open62541/open62541/jobs/287631673)
I already tried to forcefully set export SONARQUBE_SKIPPED=false but it is still skipped. How can I find out why the scanner analysis is skipped?
Related questions:
As you can read in the Travis CI logs, at line 556:
Skipping SonarCloud Scan because this branch is not master or it does not match declared branches
This is because you haven't activated analysis on that "feature/sonarcloud" branch. As described in the official documentation, you can achieve that like this:
addons:
sonarcloud:
organization: open62541
token:
secure: "..."
branches:
- master
- feature/sonarcloud
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With