Mohammed Toufeeq Ahamed
09/20/2023, 9:46 AMksp {
arg("komapper.enumStrategy", "ordinal")
arg("komapper.namingStrategy", "UPPER_SNAKE_CASE")
}
Any help would be really helpful. Thanks!glureau
09/20/2023, 9:51 AMclass MyPlugin : Plugin<Project> {
override fun apply(target: Project) {
target.apply(plugin = "com.google.devtools.ksp")
target.extensions.configure(KspExtension::class.java) {
arg("komapper.enumStrategy", "ordinal")
arg("komapper.namingStrategy", "UPPER_SNAKE_CASE")
}
}
}
Something like thatglureau
09/20/2023, 9:52 AMMohammed Toufeeq Ahamed
09/20/2023, 9:55 AMYang
09/20/2023, 10:55 AMYOUNG HO CHA
09/21/2023, 12:23 AMwithPlugin
and getByType
like this.
https://github.com/ganadist/VersionCodeDemo/blob/main/build-logic/convention/src/m[…]otlin/com/myapplication/android/builder/AnnotationProcessors.ktYang
09/21/2023, 2:27 AMafterEvaluate
doesn’t work for me is the value of my args come from a custom plugin extension which uses lazy providers like val myValue: Property<Boolean>
Because `KspExtension`’s arg
require the lazy properties to be evaluated eagerly but the values aren’t be available during configuration, the arg
value is never set, unless I wrap the config block inside an afterEvaluate
to call the arg("key", "value")
after the values provided via the custom extension are available.glureau
09/21/2023, 7:06 AM