-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathbuild.gradle.kts
More file actions
78 lines (67 loc) · 1.98 KB
/
Copy pathbuild.gradle.kts
File metadata and controls
78 lines (67 loc) · 1.98 KB
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
plugins {
java
`java-library`
`maven-publish`
id("net.kyori.indra") version "4.0.0"
id("net.kyori.indra.licenser.spotless") version "4.0.0"
id("net.kyori.indra.checkstyle") version "4.0.0"
}
group = "eu.mikart.adventure"
version = "1.1.0"
description = "Adventure platform implementation for Hytale"
repositories {
mavenCentral()
maven("https://maven.hytale.com/release")
}
dependencies {
api("net.kyori:adventure-text-serializer-gson:5.1.1")
api("net.kyori:adventure-text-serializer-ansi:5.1.1")
compileOnly("com.hypixel.hytale:Server:0.5.6")
checkstyle("ca.stellardrift:stylecheck:0.2.1")
}
java {
toolchain {
languageVersion.set(JavaLanguageVersion.of(25))
}
withSourcesJar()
withJavadocJar()
}
indra {
javaVersions {
target(25)
minimumToolchain(25)
testWith(25)
}
mitLicense()
github("ArikSquad", "adventure-platform-hytale")
}
publishing {
publications {
create<MavenPublication>("mavenJava") {
groupId = project.group.toString()
artifactId = "adventure-platform-hytale"
version = project.version.toString()
from(components["java"])
}
}
repositories {
val isSnapshot = project.version.toString().endsWith("SNAPSHOT")
val repoUrl = if (isSnapshot) {
"https://repo.codemc.io/repository/ArikSquad/"
} else {
"https://repo.codemc.io/repository/ArikSquad/"
}
maven(repoUrl) {
val mavenUsername = System.getenv("JENKINS_USERNAME")
?: findProperty("mavenUsername") as String?
val mavenPassword = System.getenv("JENKINS_PASSWORD")
?: findProperty("mavenPassword") as String?
if (mavenUsername != null && mavenPassword != null) {
credentials {
username = mavenUsername
password = mavenPassword
}
}
}
}
}