0

I got a android lint-result.xml and I`m trying to put the result of lint-result.xml to SonarQube server.

I have set build.gradle like below but it doesn`t working.

build.gradle

sonarqube {
    properties {
        property 'sonar.projectName', 'Sonar Gradle Test 2'
        property 'sonar.projectKey', 'com.test:gradletest2'
        property "sonar.host.url", "http://localhost:9000"
        property "sonar.login", "admin"
        property "sonar.password", "admin"
        property "sonar.exclusions", "**/*Test*/**, *.json, **/.gradle/**, **/R.class, **/R.java"
        property "sonar.android.lint.report", "D:/01_Dev/workspace_android/MyApplication/app/build/reports/lint-results.xml"
    }
}
Bh Yu
  • 17
  • 3

1 Answers1

0

Actually, you have to install Android Lint Plugin (https://github.com/jvilya/sonar-android-plugin) to SonarQube.

Here are the settings

sonarqube {
    properties {
        property "sonar.android.lint.reportPaths", "build/reports/lint-results.xml"
    }
}
Ilya Tretyakov
  • 6,848
  • 3
  • 28
  • 45