gradle-plugins/gradle/compile/groovy.gradle

29 lines
660 B
Groovy

apply plugin: 'groovy'
dependencies {
implementation libs.groovy.core
}
compileGroovy {
sourceCompatibility = JavaVersion.VERSION_17
targetCompatibility = JavaVersion.VERSION_17
}
compileTestGroovy {
sourceCompatibility = JavaVersion.VERSION_17
targetCompatibility = JavaVersion.VERSION_17
}
tasks.withType(GroovyCompile) {
options.compilerArgs
if (!options.compilerArgs.contains("-processor")) {
options.compilerArgs.add('-proc:none')
}
}
task groovydocJar(type: Jar) {
dependsOn groovydoc
from groovydoc.destinationDir
archiveClassifier.set('groovydoc')
}
tasks.assemble.dependsOn(tasks.groovydocJar)