Buzzer/build.gradle.kts

51 lines
1.5 KiB
Plaintext
Raw Normal View History

2021-11-07 13:53:41 +01:00
import org.jetbrains.kotlin.gradle.tasks.KotlinCompile
2021-09-25 12:24:28 +02:00
val ktor_version: String by project
val kotlin_version: String by project
val logback_version: String by project
val kotlinx_html_version: String by project
plugins {
application
kotlin("jvm")
id("com.github.johnrengelman.shadow")
2021-09-25 12:24:28 +02:00
}
group = "de.pheerai.buzzer"
2022-05-26 11:26:31 +02:00
version = "0.0.3"
2021-11-07 13:53:41 +01:00
2021-09-25 12:24:28 +02:00
application {
mainClass.set("de.pheerai.buzzer.ApplicationKt")
2022-05-26 11:26:31 +02:00
applicationDefaultJvmArgs =
listOf("--add-exports=java.base/jdk.internal.misc=ALL-UNNAMED", "-Dio.netty.tryReflectionSetAccessible=true")
2021-09-25 12:24:28 +02:00
}
repositories {
mavenCentral()
2022-05-26 11:26:31 +02:00
google()
2021-09-25 12:24:28 +02:00
}
dependencies {
implementation("io.ktor:ktor-server-core:$ktor_version")
implementation("io.ktor:ktor-server-netty:$ktor_version")
2022-05-26 11:26:31 +02:00
implementation("io.ktor:ktor-server-websockets:$ktor_version")
implementation("io.ktor:ktor-server-html-builder:$ktor_version")
implementation("org.jetbrains.kotlinx:kotlinx-html-jvm:$kotlinx_html_version")
2021-09-25 12:24:28 +02:00
implementation("ch.qos.logback:logback-classic:$logback_version")
testImplementation("io.ktor:ktor-server-tests:$ktor_version")
testImplementation("org.jetbrains.kotlin:kotlin-test:$kotlin_version")
}
2021-11-07 13:53:41 +01:00
tasks {
withType<JavaCompile>().configureEach {
sourceCompatibility = JavaVersion.VERSION_17.toString()
targetCompatibility = JavaVersion.VERSION_17.toString()
2021-11-07 13:53:41 +01:00
}
withType<KotlinCompile>().configureEach {
kotlinOptions {
jvmTarget = JavaVersion.VERSION_17.toString()
2021-11-07 13:53:41 +01:00
}
}
}