forked from Hendrix-Shen/Bilibili-Danmaku
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild.gradle
53 lines (46 loc) · 1.51 KB
/
build.gradle
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
plugins {
id("maven-publish")
id("fabric-loom").version("1.2-SNAPSHOT").apply(false)
// https://github.com/Juuxel/LoomQuiltflower
id("io.github.juuxel.loom-quiltflower").version("1.10.0").apply(false)
// https://github.com/ReplayMod/preprocessor
// https://github.com/Fallen-Breath/preprocessor
id("com.replaymod.preprocess").version("SNAPSHOT")
}
preprocess {
def mc1144 = createNode("1.14.4", 1_14_04, "mojang")
def mc1152 = createNode("1.15.2", 1_15_02, "mojang")
def mc1165 = createNode("1.16.5", 1_16_05, "mojang")
def mc1171 = createNode("1.17.1", 1_17_01, "mojang")
def mc1182 = createNode("1.18.2", 1_18_02, "mojang")
def mc1192 = createNode("1.19.2", 1_19_02, "mojang")
def mc1194 = createNode("1.19.4", 1_19_04, "mojang")
def mc1201 = createNode("1.20.1", 1_20_01, "mojang") // root
mc1144.link(mc1152, null)
mc1152.link(mc1165, null)
mc1165.link(mc1171, null)
mc1171.link(mc1182, null)
mc1182.link(mc1192, null)
mc1192.link(mc1194, null)
mc1194.link(mc1201, null)
}
def ENV = System.getenv()
String realVersion = "${project.mod_version}"
if (ENV.BUILD_NUMBER) {
realVersion += ".${ENV.BUILD_NUMBER}"
} else {
realVersion += ".0"
}
if (ENV.COMMIT_SHA) {
realVersion += "+${ENV.COMMIT_SHA}"
}
if (ENV.BUILD_TYPE) {
if (ENV.BUILD_TYPE == "RELEASE") {
realVersion += "-stable"
} else if (ENV.BUILD_TYPE == "BETA") {
realVersion += "-beta"
}
} else {
realVersion += "-dev"
}
version = realVersion