Refactor more tasks to lazy API
This commit is contained in:
@@ -35,7 +35,7 @@ projectTest {
|
||||
exclude("**/benchmark/**")
|
||||
}
|
||||
|
||||
val compactClasspath by tasks.creating(Jar::class) {
|
||||
val compactClasspath by tasks.registering(Jar::class) {
|
||||
archiveAppendix.set("classpath")
|
||||
inputs.files(sourceSets["main"].runtimeClasspath + sourceSets["test"].runtimeClasspath)
|
||||
doFirst {
|
||||
@@ -46,7 +46,7 @@ val compactClasspath by tasks.creating(Jar::class) {
|
||||
}
|
||||
}
|
||||
|
||||
val jmhBytecode by tasks.creating(JavaExec::class) {
|
||||
val jmhBytecode by tasks.registering(JavaExec::class) {
|
||||
tasks["classes"].mustRunAfter(tasks["clean"])
|
||||
tasks["compactClasspath"].mustRunAfter(tasks["classes"])
|
||||
dependsOn(tasks["clean"])
|
||||
@@ -68,14 +68,14 @@ tasks {
|
||||
}
|
||||
}
|
||||
|
||||
val jmhCompile by tasks.creating(JavaCompile::class) {
|
||||
val jmhCompile by tasks.registering(JavaCompile::class) {
|
||||
/*classpath = sourceSets["test"].runtimeClasspath + files("${project.buildDir}/generated-sources/jmh/")
|
||||
|
||||
source(fileTree("${project.buildDir}/generated-sources/jmh/"))
|
||||
destinationDir = file("${project.buildDir}/generated-classes/jmh/")*/
|
||||
}
|
||||
|
||||
val jmhExec by tasks.creating(JavaExec::class) {
|
||||
val jmhExec by tasks.registering(JavaExec::class) {
|
||||
dependsOn(tasks["compileTestJava"])
|
||||
doFirst {
|
||||
classpath = files(
|
||||
|
||||
Reference in New Issue
Block a user