-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.gradle.kts
84 lines (65 loc) · 1.81 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
82
83
84
import com.github.jengelman.gradle.plugins.shadow.tasks.ShadowJar
plugins {
id("java")
id("com.github.johnrengelman.shadow") version "8.1.1"
id("maven-publish")
}
group = "org.teleight"
version = "1.0"
allprojects {
repositories {
mavenCentral()
mavenLocal()
//TdLight
maven("https://mvn.mchv.eu/repository/mchv/")
}
}
dependencies {
//Tests
testImplementation(platform("org.junit:junit-bom:5.9.2"))
testImplementation("org.junit.jupiter:junit-jupiter")
//Checker
implementation("org.checkerframework:checker:3.39.0")
implementation("org.checkerframework:checker-qual:3.39.0")
//Annotations
implementation("org.jetbrains:annotations:24.1.0")
//TdLight
val tdlightVersion = project.property("tdlight_version");
compileOnly(platform("it.tdlight:tdlight-java-bom:${tdlightVersion}"))
compileOnly("it.tdlight:tdlight-java:${tdlightVersion}")
}
sourceSets {
main {
java {
srcDir(file("src/autogenerated/java"))
}
}
}
tasks.test {
useJUnitPlatform()
}
val javadocJar by tasks.registering(Jar::class) {
archiveClassifier.set("javadoc")
from(sourceSets.getByName("main").allSource)
archiveFileName.set("TeleightTd-javadoc.jar")
}
val sourcesJar by tasks.registering(Jar::class) {
archiveClassifier.set("sources")
from(sourceSets.getByName("main").allSource)
archiveFileName.set("TeleightTd-sources.jar")
}
publishing {
publications {
create<MavenPublication>("maven") {
artifactId = "TeleightTd"
artifact(javadocJar)
artifact(sourcesJar)
project.shadow.component(this)
}
}
}
tasks.withType<ShadowJar> {
archiveClassifier.set("")
archiveVersion.set("")
archiveFileName.set("TeleightTd.jar")
}