-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.gradle.kts
61 lines (50 loc) · 1.47 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
plugins {
id("java")
id("java-library")
id("maven-publish")
}
group = "net.thenextlvl"
version = "1.0.2"
java {
toolchain.languageVersion = JavaLanguageVersion.of(21)
withSourcesJar()
withJavadocJar()
}
tasks.compileJava {
options.release.set(21)
}
repositories {
mavenCentral()
maven("https://repo.thenextlvl.net/releases")
maven("https://repo.papermc.io/repository/maven-public/")
}
dependencies {
testImplementation(platform("org.junit:junit-bom:5.11.4"))
testImplementation("org.junit.jupiter:junit-jupiter")
testImplementation("net.thenextlvl.core:files:2.0.0")
compileOnly("net.thenextlvl.core:annotations:2.0.1")
compileOnly("org.projectlombok:lombok:1.18.36")
compileOnly("org.jetbrains:annotations:26.0.1")
api("com.google.guava:guava:33.4.0-jre")
api("com.google.code.gson:gson:2.11.0")
api("com.velocitypowered:velocity-api:3.3.0-SNAPSHOT") {
isTransitive = false
}
annotationProcessor("org.projectlombok:lombok:1.18.36")
}
tasks.test {
useJUnitPlatform()
}
publishing {
publications.create<MavenPublication>("maven") {
from(components["java"])
}
repositories.maven {
val channel = if ((version as String).contains("-pre")) "snapshots" else "releases"
url = uri("https://repo.thenextlvl.net/$channel")
credentials {
username = System.getenv("REPOSITORY_USER")
password = System.getenv("REPOSITORY_TOKEN")
}
}
}