-
Notifications
You must be signed in to change notification settings - Fork 8
Closed
Description
Documentation should be updated.
On page https://github.com/Lucas3oo/sonarlint-gradle-plugin?tab=readme-ov-file#sonarlint-ci-reports there is an example:
sonarlintMain {
reports {
xml.enabled = true // default false
sarif.enabled = true // default false
}
}It doesn't work with Gradle 8.9 when using Kotlin syntax, i.e. file build.gradle.kts. I made it work as follows:
plugins {
id("se.solrike.sonarlint") version "2.0.0"
}
dependencies {
sonarlintPlugins("org.sonarsource.java:sonar-java-plugin:8.2.0.36672")
}
tasks.sonarlintMain {
ignoreFailures = false
reports {
reports.create("xml") {
enabled = true
outputLocation = layout.buildDirectory.file("reports/sonarlint/sonarlint.xml")
}
reports.create("html") {
enabled = true
outputLocation = layout.buildDirectory.file("reports/sonarlint/sonarlint.html")
}
}
}(Note: tasks.sonarlintMain<se.solrike.sonarlint.Sonarlint> also works.)
Also, I'd like to ask how is it possible to change the minimum level in failures/reports. For example, I want Major️ and Minor but not Info. Can this be documented?
Metadata
Metadata
Assignees
Labels
No labels