-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathbuild.gradle
More file actions
166 lines (130 loc) · 4.83 KB
/
build.gradle
File metadata and controls
166 lines (130 loc) · 4.83 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
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
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
plugins {
id 'dev.architectury.loom' version '1.10-SNAPSHOT'
id 'maven-publish'
id 'com.github.johnrengelman.shadow' version '8.1.1'
}
group = project.maven_group
version = project.mod_version
base {
archivesName = project.archives_name
}
loom {
silentMojangMappingsLicense()
forge {
mixinConfig 'zps.mixins.json'
}
}
repositories {
// Add repositories to retrieve artifacts from in here.
// You should only use this when depending on other mods because
// Loom adds the essential maven repositories to download Minecraft and libraries from automatically.
// See https://docs.gradle.org/current/userguide/declaring_repositories.html
// for more information about repositories.
mavenLocal()
mavenCentral()
maven { url = "https://maven.createmod.net" }
maven {url = "https://api.modrinth.com/maven"}
maven { url = "https://maven.ithundxr.dev/mirror" }
flatDir {
dirs 'libs'
}
maven {
// location of the maven that hosts JEI files since January 2023
name = "Jared's maven"
url = "https://maven.blamejared.com/"
}
maven {
name = "Valkyrien Skies Internal"
url = 'https://maven.valkyrienskies.org'
content {
includeGroupByRegex "org.valkyrien.*"
}
}
}
configurations {
shadow
implementation.extendsFrom(shadow)
}
dependencies {
minecraft "net.minecraft:minecraft:$project.minecraft_version"
mappings loom.officialMojangMappings()
forge "net.minecraftforge:forge:$project.forge_version"
implementation("io.github.llamalad7:mixinextras-common:0.5.0")
implementation("io.github.llamalad7:mixinextras-forge:0.5.0")
annotationProcessor("io.github.llamalad7:mixinextras-common:0.5.0")
include("io.github.llamalad7:mixinextras-forge:0.5.0")
modImplementation("maven.modrinth:fusion-connected-textures:1.2.12-forge-mc1.20.1")
include(modImplementation("ace.actually.radios:radios:1.2.0"))
// TTS
shadow("javax.speech:jsapi:1.0")
forgeRuntimeLibrary("javax.speech:jsapi:1.0")
shadow("com.sun.speech.freetts:freetts:1.2")
forgeRuntimeLibrary("com.sun.speech.freetts:freetts:1.2")
modImplementation("com.simibubi.create:create-$minecraft_version:$create_version:slim") { transitive = false }
modImplementation("com.tterrag.registrate:Registrate:$registrate_version")
modRuntimeOnly("mezz.jei:jei-1.20.1-forge:15.20.0.129")
modRuntimeOnly("maven.modrinth:spark:1.10.53-forge")
compileOnly ("org.valkyrienskies.core:api:1.1.0+b714ef303e") {transitive = false}
compileOnly ("org.joml:joml-primitives:1.10.0")
modCompileOnly("maven.modrinth:valkyrien-skies:1.20.1-forge-2.4.10")
//noinspection DifferentStdlibGradleVersion
api "org.jetbrains.kotlin:kotlin-stdlib-jdk8:1.9.10"
api "org.jetbrains.kotlin:kotlin-reflect:1.9.10"
include (modImplementation("net.createmod.ponder:Ponder-Forge-${minecraft_version}:${ponder_version}"))
include (modImplementation("dev.engine-room.flywheel:flywheel-forge-${minecraft_version}:${flywheel_version}"))
testImplementation 'org.junit.jupiter:junit-jupiter-api:5.10.0'
testRuntimeOnly 'org.junit.jupiter:junit-jupiter-engine:5.10.0'
}
sourceSets {
main {
resources {
srcDir 'src/main/resources_extra'
}
}
}
processResources {
inputs.property 'version', project.version
from('resources_extra') {
into ''
include '**/*'
}
filesMatching('META-INF/mods.toml') {
expand version: project.version
}
}
java {
// Loom will automatically attach sourcesJar to a RemapSourcesJar task and to the "build" task
// if it is present.
// If you remove this line, sources will not be generated.
withSourcesJar()
sourceCompatibility = JavaVersion.VERSION_17
targetCompatibility = JavaVersion.VERSION_17
}
tasks.withType(JavaCompile).configureEach {
it.options.release = 17
}
test {
useJUnitPlatform()
// NOTE: Mixin agent cannot be used here because Forge mixins require ModLauncher
// infrastructure that isn't available in plain JUnit tests. See MIXIN_TESTING_STRATEGY.md
// for explanation of our testing approach.
}
shadowJar {
// Merge FreeTTS jar contents into the root of the output jar
configurations = [project.configurations.shadow]
// Merge service files so FreeTTS voice registration works
mergeServiceFiles()
// Don't relocate - FreeTTS needs its original package paths
// Exclude duplicate META-INF signatures that would break jar validation
exclude 'META-INF/*.SF'
exclude 'META-INF/*.DSA'
exclude 'META-INF/*.RSA'
exclude 'META-INF/*.MF'
archiveClassifier.set('shadow-dev')
}
// Make the remapJar task use the shadow jar as its input
remapJar {
dependsOn shadowJar
inputFile = shadowJar.archiveFile
archiveClassifier.set('')
}