-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathbuild.gradle
82 lines (74 loc) · 2.68 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
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
plugins {
id 'maven-publish'
id "com.modrinth.minotaur" version "2.+"
id "io.github.goooler.shadow" version "8.1.7" apply false
id "dev.architectury.loom" version "1.7-SNAPSHOT" apply false
id "io.github.p03w.machete" version "2.+" apply false
// https://github.com/ReplayMod/preprocessor
// https://github.com/Fallen-Breath/preprocessor
id 'com.replaymod.preprocess' version 'ce1aeb2b'
// https://github.com/Fallen-Breath/yamlang
id 'me.fallenbreath.yamlang' version '1.3.1' apply false
}
preprocess {
def mc1201_fabric = createNode('1.20.1-fabric', 1_20_01, '')
def mc1202_fabric = createNode('1.20.2-fabric', 1_20_02, '')
def mc121_fabric = createNode('1.21-fabric', 1_21_00, '')
def mc1212_fabric = createNode('1.21.2-fabric', 1_21_02, '')
def mc1201_forge = createNode('1.20.1-forge', 1_20_01, '')
def mc1202_forge = createNode('1.20.2-forge', 1_20_02, '')
def mc1205_neoforge = createNode('1.20.5-neoforge', 1_20_05, '')
def mc121_neoforge = createNode('1.21-neoforge', 1_21_00, '')
mc1201_fabric.link(mc1202_fabric, null)
mc1202_fabric.link(mc121_fabric, null)
mc121_fabric.link(mc1212_fabric, null)
mc1201_fabric.link(mc1201_fabric, null)
mc1202_fabric.link(mc1202_fabric, null)
mc121_fabric.link(mc121_fabric, null)
mc1212_fabric.link(mc1212_fabric, null)
mc1201_fabric.link(mc1201_forge, null)
mc1202_fabric.link(mc1202_forge, null)
mc1202_fabric.link(mc1205_neoforge, null)
mc121_fabric.link(mc121_neoforge, null)
}
publishing {
repositories {
maven {
name = "Kel_Cuprum_Repository"
url = "https://repo.kelcuprum.ru/test"
credentials {
username = System.getenv("MAVEN_USERNAME")
password = System.getenv("MAVEN_PASSWORD")
}
}
}
}
tasks.register('modrinthAll') {
subprojects {
dependsOn project.tasks.named('modrinth').get()
}
}
tasks.register('buildAndGather') {
subprojects {
dependsOn project.tasks.named('build').get()
}
doFirst {
println 'Gathering builds'
def buildLibs = {
p -> p.buildDir.toPath().resolve('libs')
}
delete fileTree(buildLibs(rootProject)) {
include '*'
}
subprojects {
copy {
from(buildLibs(project)) {
include '*.jar'
exclude '*-dev.jar', '*-sources.jar', '*-all.jar'
}
into buildLibs(rootProject)
duplicatesStrategy DuplicatesStrategy.INCLUDE
}
}
}
}