Gradle: how to get default resources output dir?
println sourceSets.main.resources.outputDir
Error:
Needs to set a non-null value before it can be retrieved
Gradle: how to get default resources output dir?
println sourceSets.main.resources.outputDir
Error:
Needs to set a non-null value before it can be retrieved
For kotlin DSL:
sourceSets.main.get().output.resourcesDir
sourceSets.main.get().output.resourcesDir
is a File
type. To cast it to String, we should call sourceSets.main.get().output.resourcesDir.toString()
–
Gobi © 2022 - 2024 — McMap. All rights reserved.