added JPMS support
This commit is contained in:
@@ -1,9 +1,10 @@
|
||||
plugins {
|
||||
id "org.jetbrains.kotlin.jvm"
|
||||
id "application"
|
||||
id "net.woggioni.gradle.envelope"
|
||||
}
|
||||
|
||||
import org.jetbrains.kotlin.gradle.tasks.KotlinCompile
|
||||
import net.woggioni.gradle.envelope.EnvelopeJarTask
|
||||
|
||||
dependencies {
|
||||
implementation group:"org.jetbrains.kotlin", name: "kotlin-stdlib-jdk8", version: getProperty("kotlin.version")
|
||||
@@ -12,31 +13,21 @@ dependencies {
|
||||
implementation group: "org.slf4j", name: "slf4j-api", version: property("slf4j.version")
|
||||
implementation group: "com.beust", name: "jcommander", version: property("jcommander.version")
|
||||
implementation rootProject
|
||||
|
||||
testRuntimeOnly group: "org.junit.jupiter", name: "junit-jupiter-engine", version: property("junit.version")
|
||||
testImplementation group: "org.junit.jupiter", name: "junit-jupiter-api", version: property("junit.version")
|
||||
testImplementation group: "org.junit.jupiter", name: "junit-jupiter-params", version: property("junit.version")
|
||||
}
|
||||
|
||||
application {
|
||||
mainClassName = "net.woggioni.jzstd.Cli"
|
||||
Provider<EnvelopeJarTask> envelopeJarTaskProvider = tasks.named('envelopeJar', EnvelopeJarTask.class) {
|
||||
mainClass = 'net.woggioni.jzstd.Cli'
|
||||
}
|
||||
|
||||
|
||||
tasks.withType(Test) {
|
||||
useJUnitPlatform()
|
||||
}
|
||||
|
||||
java {
|
||||
sourceCompatibility = JavaVersion.VERSION_1_8
|
||||
targetCompatibility = JavaVersion.VERSION_1_8
|
||||
tasks.named('envelopeRun', JavaExec) {
|
||||
args = ['--help']
|
||||
}
|
||||
|
||||
tasks.withType(KotlinCompile.class).configureEach {
|
||||
kotlinOptions {
|
||||
languageVersion = "1.5"
|
||||
apiVersion = "1.5"
|
||||
jvmTarget = "1.8"
|
||||
languageVersion = "1.6"
|
||||
apiVersion = "1.6"
|
||||
jvmTarget = "11"
|
||||
javaParameters = true
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user