Scanner command used when applicable (./gradlew sonar -D…options…)
Languages of the repository: Kotlin
I’m running sonar on android project using gradle.
I’m doing that on Bitrise.
It works well, but there are couple of warnings in the log when running the sonar gradle task.
One of them is related to linting, we do not depend on android linting.
So, we need a way to exclude that lint report from Sonar.
Notice that we don’t rung gradle lint task. That’s why the lint xml report file is not generated.
How can we do that?
The error message:
Unable to import Android Lint report file(s):
The report file(s) can not be found. Check that the property 'sonar.androidLint.reportPaths' is correctly configured.
Also, we got these two warnings:
No merge base found between HEAD and refs/remotes/origin/main
Could not report issue with code highlighting, using plain text instead. Check whether the product is outdated.
Hello @mahmoud, the warning happens because you’re most likely using an old version of SonarLint that doesn’t support the code highlighting feature. It is not an issue, simply the code that raises the issue won’t be highlighted.
I didn’t include the SonarLint.
I only use the sonar for gradle with version 22.214.171.12468 which is the latest version.
If the linting task is included in that version, then it must be the most up-to-date version.
Also, I did not include any other dependency for sonar linting.
How can I disable the liniting from sonar for gradle then to remove that warning?