forked from Core2002/FiFuPowered
-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.gradle.kts
66 lines (58 loc) · 1.85 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
import com.github.jengelman.gradle.plugins.shadow.tasks.ShadowJar
val kotlin_version: String by project
val junit_version: String by project
val lombok_version: String by project
plugins {
kotlin("jvm") version "2.0.21"
id("com.github.johnrengelman.shadow") version "8.1.1"
}
subprojects {
apply {
plugin("java")
plugin("com.github.johnrengelman.shadow")
}
group = "fun.fifu.powered"
version = "1.21.4-SNAPSHOT"
val api_version = "1.21"
repositories {
mavenLocal()
maven("https://maven.aliyun.com/repository/public/")
maven("https://maven.aliyun.com/repository/gradle-plugin/")
maven("https://maven.aliyun.com/repository/apache-snapshots/")
maven("https://papermc.io/repo/repository/maven-public/")
maven("https://libraries.minecraft.net/")
mavenCentral()
}
dependencies {
implementation(fileTree("./lib"))
testImplementation("org.junit.jupiter:junit-jupiter-api:$junit_version")
testRuntimeOnly("org.junit.jupiter:junit-jupiter-engine:$junit_version")
compileOnly("io.papermc.paper:paper-api:1.21.4-R0.1-SNAPSHOT")
compileOnly("org.projectlombok:lombok:$lombok_version")
}
tasks.withType<ShadowJar> {
destinationDirectory = file("$rootDir/build/libs")
}
tasks {
register<Copy>("copyBinaryResources") {
from("src/main/resources") {
include("*.db")
}
into("build/resources/main")
}
processResources {
dependsOn("copyBinaryResources")
exclude("*.db")
expand(
"version" to project.version,
"api_version" to api_version
)
}
build {
dependsOn(shadowJar)
}
test {
useJUnitPlatform()
}
}
}