-
Notifications
You must be signed in to change notification settings - Fork 1
/
build.gradle
100 lines (83 loc) · 2.45 KB
/
build.gradle
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
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
plugins {
id 'java'
id 'maven-publish'
id 'org.jetbrains.kotlin.jvm' version '1.6.20'
id 'org.jetbrains.kotlin.plugin.serialization' version '1.6.20'
id "com.github.ben-manes.versions" version "0.42.0"
}
repositories {
google()
mavenCentral()
}
sourceCompatibility = 1.8
description = 'battlesnake-quickstart'
group = 'io.battlesnake'
version = '0.14.0'
dependencies {
implementation "org.jetbrains.kotlin:kotlin-stdlib:$kotlin_version"
implementation "org.jetbrains.kotlinx:kotlinx-serialization-json:$serialization_version"
implementation "io.ktor:ktor-server:$ktor_version"
implementation "io.ktor:ktor-server-cio:$ktor_version"
implementation "io.ktor:ktor-server-html-builder:$ktor_version"
implementation "io.ktor:ktor-serialization-kotlinx-json:$ktor_version"
testImplementation "io.ktor:ktor-server-tests:$ktor_version"
implementation "io.github.microutils:kotlin-logging:$logging_version"
implementation "ch.qos.logback:logback-classic:$logback_version"
implementation "org.slf4j:jul-to-slf4j:$slf4j_version"
testImplementation "org.amshove.kluent:kluent:$kluent_version"
testImplementation "org.junit.jupiter:junit-jupiter-api:$junit_version"
testImplementation "org.jetbrains.kotlin:kotlin-test:$test_version"
testRuntimeOnly "org.junit.jupiter:junit-jupiter-engine:$junit_version"
}
// gradle 7
publishing {
publications {
mavenJava(MavenPublication) {
from components.java
versionMapping {
usage('java-api') {
fromResolutionOf('runtimeClasspath')
}
usage('java-runtime') {
fromResolutionResult()
}
}
}
}
}
task sourcesJar(type: Jar, dependsOn: classes) {
classifier = 'sources'
from sourceSets.main.allSource
}
task javadocJar(type: Jar, dependsOn: javadoc) {
classifier = 'javadoc'
from javadoc.destinationDir
}
artifacts {
archives sourcesJar
}
java {
withSourcesJar()
}
compileKotlin {
kotlinOptions {
jvmTarget = '1.8'
freeCompilerArgs += ['-opt-in=kotlin.time.ExperimentalTime',
'-opt-in=kotlin.ExperimentalStdlibApi']
}
}
compileTestKotlin {
kotlinOptions {
jvmTarget = '1.8'
freeCompilerArgs += ['-opt-in=kotlin.time.ExperimentalTime',
'-opt-in=kotlin.ExperimentalStdlibApi']
}
}
test {
useJUnitPlatform()
testLogging {
events "passed", "skipped", "failed", "standardOut", "standardError"
exceptionFormat "full"
showStandardStreams = true
}
}