-
Notifications
You must be signed in to change notification settings - Fork 7
/
build.gradle.groovy
72 lines (58 loc) · 1.67 KB
/
build.gradle.groovy
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
59
60
61
62
63
64
65
66
67
68
69
70
71
72
group 'de.swirtz.kotlin'
version '1.0-SNAPSHOT'
buildscript {
ext.ktor_version = '0.9.0'
ext.kotlin_version = '1.1.51'
repositories {
mavenCentral()
}
dependencies {
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
}
}
apply plugin: 'kotlin'
apply plugin: 'application'
sourceCompatibility = 1.8
kotlin {
experimental {
coroutines "enable"
}
}
compileKotlin {
kotlinOptions.jvmTarget = "1.8"
}
compileTestKotlin {
kotlinOptions.jvmTarget = "1.8"
}
repositories {
jcenter()
mavenCentral()
maven { url "http://dl.bintray.com/kotlin/ktor" }
maven { url "https://dl.bintray.com/kotlin/kotlinx" }
}
dependencies {
compile "org.jetbrains.kotlin:kotlin-stdlib-jre8:$kotlin_version"
compile "org.jetbrains.kotlinx:kotlinx-html-jvm:0.6.4"
compile "io.ktor:ktor:$ktor_version"
compile "io.ktor:ktor-gson:$ktor_version"
compile "io.ktor:ktor-html-builder:$ktor_version"
compile "io.ktor:ktor-server-netty:$ktor_version"
compile "ch.qos.logback:logback-classic:1.2.1"
compile group: 'org.slf4j', name: 'slf4j-api', version: '1.7.25'
testCompile "io.ktor:ktor-server-test-host:$ktor_version"
testCompile group: 'junit', name: 'junit', version: '4.12'
}
sourceSets {
main.kotlin.srcDirs += 'src/main/kotlin'
test.kotlin.srcDirs += 'src/test/kotlin'
}
archivesBaseName = 'ktorapp'
version = '1.0-SNAPSHOT'
group = 'de.swirtz.kotlin.webdev'
mainClassName = 'de.swirtz.kotlin.webdev.ktor.KtorServerKt'
jar {
manifest {
attributes 'Main-Class': "$mainClassName"
}
from { configurations.compile.collect { it.isDirectory() ? it : zipTree(it) } }
}