Matt Nelson
02/09/2023, 3:59 PMplugins {
id("my-plugin")
}
myPluginExtension {
// Configure it
}
// I'm trying to ensure that at this line here in the build.gradle(kts) file (after closure), everything gets configured
open class MyPlugin: Plugin<Project> {
override fun apply(target: Project) {
val extension = target.extensions.create(
"myPluginExtension",
MyPluginExtension::class.java,
target,
)
// What I'm trying to do, much like an action
// that gets lazily invoked.
extension.afterClosure { it ->
it.configure()
}
}
private val MyPluginExtension.configure() {
// setup
}
}
eygraber
02/09/2023, 4:55 PMBig Chungus
02/09/2023, 7:13 PMMatt Nelson
02/09/2023, 7:40 PMalpha02
then.
https://github.com/05nelsonm/gradle-kmp-configuration-plugin