This repository has been archived by the owner on Apr 28, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 1
/
build.gradle.kts
81 lines (68 loc) · 2.11 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
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
import org.jetbrains.dokka.gradle.DokkaTask
import org.jetbrains.kotlin.gradle.tasks.KotlinCompile
plugins {
java
kotlin("jvm") version "1.3.30"
id("com.jfrog.artifactory") version "4.9.0"
`maven-publish`
id("org.jetbrains.dokka") version "0.9.17"
}
allprojects {
group = "io.github.cottonmc"
version = "0.5.0-beta.3-SNAPSHOT"
repositories {
jcenter()
}
tasks.withType<KotlinCompile> {
kotlinOptions.jvmTarget = "1.8"
}
if (rootProject.file("private.gradle").exists()) {
apply(from = rootProject.file("private.gradle"))
}
//the artifactory block is written in the groovy dsl
apply(from = rootProject.file("artifactory.gradle"))
tasks.create<Zip>("sourcesJar") {
extension = "jar"
classifier = "sources"
from("src/main/kotlin")
from("src/main/resources")
}
}
publishing {
publications {
create<MavenPublication>("maven") {
from(components["java"])
artifact(tasks["sourcesJar"])
}
}
}
dependencies {
api(kotlin("stdlib-jdk8"))
api(kotlin("reflect"))
api("com.google.code.gson:gson:2.8.5")
api("io.arrow-kt:arrow-core-data:0.9.0")
implementation("io.arrow-kt:arrow-core-extensions:0.9.0")
implementation("io.arrow-kt:arrow-typeclasses:0.9.0")
implementation("org.jetbrains.kotlinx:kotlinx-coroutines-core:1.2.0")
implementation("com.google.flogger:flogger:0.4")
testImplementation("org.junit.jupiter:junit-jupiter-api:5.2.0")
testImplementation("io.strikt:strikt-core:0.17.1")
testImplementation("org.spekframework.spek2:spek-dsl-jvm:2.0.4")
testRuntimeOnly("org.spekframework.spek2:spek-runner-junit5:2.0.4")
testRuntimeOnly("org.junit.jupiter:junit-jupiter-engine:5.2.0")
}
tasks.withType<DokkaTask> {
outputFormat = "html"
outputDirectory = "$buildDir/dokka"
includes = listOf("src/docs/docs.md")
}
tasks.withType<Test> {
useJUnitPlatform {
includeEngines("spek2")
}
}
tasks.withType<KotlinCompile> {
kotlinOptions {
freeCompilerArgs += "-Xuse-experimental=kotlin.Experimental"
}
}