-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathbuild.gradle.kts
More file actions
51 lines (42 loc) · 1.21 KB
/
build.gradle.kts
File metadata and controls
51 lines (42 loc) · 1.21 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
var envVersion: String = System.getenv("VERSION") ?: "9.9.9"
if (envVersion.startsWith("v"))
envVersion = envVersion.trimStart('v')
plugins {
id("java")
id("maven-publish")
}
base.archivesName = "services"
group = "dev.compactmods"
version = envVersion
repositories {
mavenCentral()
maven("https://libraries.minecraft.net")
}
dependencies {
implementation("it.unimi.dsi:fastutil:8.5.12")
testImplementation(libs.bundles.jmh)
testImplementation(mojang.dfu)
testImplementation(libs.javafaker)
testImplementation(libs.commons.io)
testImplementation(platform("org.junit:junit-bom:5.10.0"))
testImplementation("org.junit.jupiter:junit-jupiter")
}
tasks.test {
useJUnitPlatform()
}
val PACKAGES_URL = System.getenv("GH_PKG_URL") ?: "https://maven.pkg.github.com/compactmods/services"
publishing {
publications.register<MavenPublication>("main") {
from(components.getByName("java"))
}
repositories {
// GitHub Packages
maven(PACKAGES_URL) {
name = "GitHubPackages"
credentials {
username = System.getenv("GITHUB_ACTOR")
password = System.getenv("GITHUB_TOKEN")
}
}
}
}