https://kotlinlang.org logo
#intellij-plugins
Title
# intellij-plugins
d

Dmitry Kandalov

06/10/2019, 6:09 PM
In
build.gradle
for a plugin I can specify other plugins it depends, e.g.
Copy code
intellij {
	plugins = ["github", "junit"]
}
however it doesn’t work with
build.gradle.kts
, e.g.
Copy code
configure<IntelliJPluginExtension> {
    plugins = arrayOf("") // <-- Val cannot be reassigned
}
Is it a bug?
b

breandan

06/10/2019, 6:37 PM
Not a bug, but a usability issue https://github.com/gradle/kotlin-dsl/issues/712
The solution is to use the custom mutator,
setPlugins("pluginA", "pluginB")
d

Dmitry Kandalov

06/10/2019, 6:41 PM
👍 Thanks a lot!
b

breandan

06/12/2023, 1:43 AM
Property assignment is now enabled by default in Gradle
8.2-rc-2
, so you can now write
plugins = listOf(...)
directly.
3 Views