-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathbuild.gradle.kts
58 lines (49 loc) · 1.45 KB
/
build.gradle.kts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
import org.jetbrains.kotlin.gradle.tasks.KotlinCompile
plugins {
kotlin("jvm") version "1.3.31"
application
}
group = "us.kesslern"
version = "1.0-SNAPSHOT"
dependencies {
implementation("org.jetbrains.kotlinx:kotlinx-coroutines-core:1.2.1")
implementation("io.ktor:ktor-network:1.1.4")
implementation("io.ktor:ktor-client-core:1.1.4")
implementation("io.ktor:ktor-client-cio:1.1.4")
implementation("io.github.microutils:kotlin-logging:1.6.24")
implementation("ch.qos.logback:logback-classic:1.2.+")
implementation("org.graalvm.sdk:graal-sdk:1.0.0-rc16")
implementation("com.beust:klaxon:5.0.1")
implementation("org.xerial:sqlite-jdbc:3.27.2.1")
implementation("org.hjson:hjson:3.0.0")
implementation(kotlin("stdlib-jdk8"))
}
repositories {
mavenCentral()
jcenter()
}
application {
mainClassName = "us.kesslern.kotbot.MainKt"
group = "us.kesslern"
applicationName = "kotbot"
}
val fatJar = task("fatJar", type = Jar::class) {
manifest {
attributes["Main-Class"] = "us.kesslern.kotbot.MainKt"
}
from({ configurations["runtimeClasspath"].map { if (it.isDirectory) it else zipTree(it) } })
with(tasks["jar"] as CopySpec)
}
tasks {
"build" {
dependsOn(fatJar)
}
}
val compileKotlin: KotlinCompile by tasks
compileKotlin.kotlinOptions {
jvmTarget = "1.8"
}
val compileTestKotlin: KotlinCompile by tasks
compileTestKotlin.kotlinOptions {
jvmTarget = "1.8"
}