with gradle-groovy it is possible to create a new configuration with:
configurations {
explode
}
dependencies {
explode (group: 'org.apache.samza', name: 'samza-shell', ext: 'tgz', classifier: 'dist', version: "$SAMZA_VERSION")
}
But I don't know how to do that with the kotlin-dsl. I tried:
val explode by configurations
dependencies {
explode(group = "org.apache.samza", name = "samza-shell", ext = "tgz", classifier = "dist", version = samzaVersion)
// "explode"(group = "org.apache.samza", name = "samza-shell", ext = "tgz", classifier = "dist", version = samzaVersion)
}
but without success. Any ideas?
To activate the Kotlin DSL, simply use the . gradle. kts extension for your build scripts in place of . gradle .
Simply, it stands for 'Domain Specific Language'. IMO, in gradle context, DSL gives you a gradle specific way to form your build scripts. More precisely, it's a plugin-based build system that defines a way of setting up your build script using (mainly) building blocks defined in various plugins.
Could you please try:
val explode by configurations.creating
or:
val explode = configurations.create("explode")
The following build.gradle.kts
script works fine:
repositories {
mavenCentral()
}
val explode by configurations.creating
dependencies {
explode("org.apache.samza:samza-shell:0.13.1")
}
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With