hello, sometimes intellij complains about my kotli...
# gradle
t
hello, sometimes intellij complains about my kotlin dsl script, though gradle then execute correctly. for instance
Copy code
plugins {
  id("org.hidetake.swagger.generator") version  "2.18.1"
}

tasks {
  withType<org.hidetake.gradle.swagger.generator.GenerateSwaggerUI> {
    dependsOn("openapi3")
    inputFile = file("$buildDir/api-spec/openapi3.json")
  }
}
org.hidetake.gradle.swagger.generator.GenerateSwaggerUI
is red, causing then
dependsOn
and
inputFile
to be not recognized
everything works from CLI. I had this problem as well in the past with other plugins, sometimes idea auto-fix itself, sometimes cache invalidation is the way to go, this time I am stuck (since few hours, so who knows, maybe at some point it will be fixed)
any suggestion?
d
Had similar problem when intellij was using different version of gradle than used from cli
Adding gradle wrapper to a project resolved intellij confusion
t
in my case the wrapper did not help. I was using
Gradle from gradle.properties
and switched to
wrapper task in gradle script
with no result
tbf, I currently have this problem with 2 tasks for which I could not find documentation based on kotlin dsl