67 lines
1.5 KiB
Kotlin
67 lines
1.5 KiB
Kotlin
plugins {
|
|
alias(libs.plugins.kotlin)
|
|
alias(libs.plugins.kotlin.serialization)
|
|
alias(libs.plugins.shadow)
|
|
id("application")
|
|
}
|
|
|
|
group = "com.mtusi.messenger"
|
|
version = "1.0.0"
|
|
|
|
repositories {
|
|
mavenCentral()
|
|
}
|
|
|
|
dependencies {
|
|
implementation(libs.kotlinx.serialization.json)
|
|
implementation(libs.logback.classic)
|
|
|
|
implementation(ktorLibs.server.core)
|
|
implementation(ktorLibs.server.netty)
|
|
implementation(ktorLibs.server.contentNegotiation)
|
|
implementation(ktorLibs.server.statusPages)
|
|
implementation(ktorLibs.server.callLogging)
|
|
implementation(ktorLibs.server.defaultHeaders)
|
|
implementation(ktorLibs.server.swagger)
|
|
implementation(ktorLibs.serialization.kotlinx.json)
|
|
|
|
testImplementation(kotlin("test"))
|
|
testImplementation(ktorLibs.server.testHost)
|
|
testImplementation(ktorLibs.client.contentNegotiation)
|
|
testImplementation(libs.kotlinx.coroutines.test)
|
|
}
|
|
|
|
kotlin {
|
|
jvmToolchain(21)
|
|
}
|
|
|
|
application {
|
|
mainClass = "io.ktor.server.netty.EngineMain"
|
|
applicationDefaultJvmArgs = listOf("-Dio.ktor.development=false")
|
|
}
|
|
|
|
sourceSets {
|
|
named("main") {
|
|
resources {
|
|
srcDir(layout.projectDirectory.dir("contracts"))
|
|
}
|
|
}
|
|
}
|
|
|
|
tasks {
|
|
test {
|
|
useJUnitPlatform()
|
|
}
|
|
|
|
shadowJar {
|
|
archiveBaseName = "messenger"
|
|
archiveClassifier = ""
|
|
archiveVersion = ""
|
|
mergeServiceFiles()
|
|
}
|
|
|
|
getByName<JavaExec>("run") {
|
|
workingDir = file("run/development")
|
|
}
|
|
}
|