-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.gradle.kts
83 lines (69 loc) · 2.37 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
plugins {
java
id("com.github.johnrengelman.shadow").version("6.1.0")
`maven-publish`
}
group = "us.ajg0702"
version = "1.3.3"
repositories {
mavenCentral()
maven { url = uri("https://jitpack.io") }
maven { url = uri("https://gitlab.com/api/v4/projects/19978391/packages/maven") }
maven { url = uri("https://repo.codemc.io/repository/nms/") }
maven { url = uri("https://hub.spigotmc.org/nexus/content/repositories/snapshots/") }
maven { url = uri("http://repo.extendedclip.com/content/repositories/placeholderapi/") }
maven { url = uri("https://repo.codemc.org/repository/maven-public") }
maven { url = uri("https://repo.citizensnpcs.co/") }
}
dependencies {
testImplementation("junit:junit:4.12")
compileOnly("com.github.MilkBowl:VaultAPI:1.7")
compileOnly(group = "org.spigotmc", name = "spigot", version = "1.16.4-R0.1-SNAPSHOT")
compileOnly("me.clip:placeholderapi:2.10.4")
compileOnly("org.xerial:sqlite-jdbc:3.32.3.2")
implementation("com.zaxxer:HikariCP:3.4.5")
implementation("org.bstats:bstats-bukkit:1.7")
implementation("us.ajg0702:ajUtils:1.0.0")
}
tasks.withType<ProcessResources> {
include("**/*.yml")
filter<org.apache.tools.ant.filters.ReplaceTokens>(
"tokens" to mapOf(
"VERSION" to project.version.toString()
)
)
}
tasks.shadowJar {
relocate("org.bstats", "us.ajg0702.leaderboards.libs")
relocate("us.ajg0702.utils", "us.ajg0702.leaderboards.libs")
relocate("com.zaxxer.hikari", "us.ajg0702.leaderboards.libs.hikari")
archiveFileName.set("${baseName}-${version}.${extension}")
exclude("junit/**/*")
exclude("org/junit/**/*")
exclude("org/hamcrest/**/*")
exclude("LICENSE-junit.txt")
}
publishing {
publications {
create<MavenPublication>("mavenJava") {
artifact(tasks["jar"])
}
}
repositories {
val mavenUrl = "https://repo.ajg0702.us/releases"
if(!System.getenv("REPO_TOKEN").isNullOrEmpty()) {
maven {
url = uri(mavenUrl)
name = "ajRepo"
credentials {
username = "plugins"
password = System.getenv("REPO_TOKEN")
}
}
}
}
}
java {
sourceCompatibility = JavaVersion.VERSION_1_8
targetCompatibility = JavaVersion.VERSION_1_8
}