aboutsummaryrefslogtreecommitdiff
path: root/build.gradle.kts
diff options
context:
space:
mode:
authorLinnea Gräf <nea@nea.moe>2024-03-07 21:55:09 +0100
committerGitHub <noreply@github.com>2024-03-07 21:55:09 +0100
commit5c8c3e81a891da36fa752d5f67886bc02ed504dd (patch)
tree0ada1c40c51a41465703d34c2962cea6d19b78da /build.gradle.kts
parentaf5543f73ffcf16cf520b7cf854a18c7e70f4237 (diff)
downloadNotEnoughUpdates-5c8c3e81a891da36fa752d5f67886bc02ed504dd.tar.gz
NotEnoughUpdates-5c8c3e81a891da36fa752d5f67886bc02ed504dd.tar.bz2
NotEnoughUpdates-5c8c3e81a891da36fa752d5f67886bc02ed504dd.zip
Fix wrong mod loader warning on modern versions of minecraft (#1030)
Diffstat (limited to 'build.gradle.kts')
-rw-r--r--build.gradle.kts16
1 files changed, 14 insertions, 2 deletions
diff --git a/build.gradle.kts b/build.gradle.kts
index 3ed5d4e4..9c859169 100644
--- a/build.gradle.kts
+++ b/build.gradle.kts
@@ -105,6 +105,10 @@ val kotlinDependencies: Configuration by configurations.creating {
configurations.implementation.get().extendsFrom(this)
}
+val mixinRTDependencies: Configuration by configurations.creating {
+ configurations.implementation.get().extendsFrom(this)
+}
+
val oneconfigQuarantineSourceSet: SourceSet = sourceSets.create("oneconfig") {
java {
srcDir(layout.projectDirectory.dir("src/main/oneconfig"))
@@ -148,7 +152,7 @@ dependencies {
shadowImplementation("com.mojang:brigadier:1.0.18")
- shadowImplementation("org.spongepowered:mixin:0.7.11-SNAPSHOT") {
+ mixinRTDependencies("org.spongepowered:mixin:0.7.11-SNAPSHOT") {
isTransitive = false // Dependencies of mixin are already bundled by minecraft
}
annotationProcessor("net.fabricmc:sponge-mixin:0.11.4+mixin.0.8.5")
@@ -224,10 +228,16 @@ tasks.remapSourcesJar {
// Use Zip instead of Jar as to not include META-INF
val kotlinDependencyCollectionJar by tasks.creating(Zip::class) {
archiveFileName.set("kotlin-libraries-wrapped.jar")
- destinationDirectory.set(project.layout.buildDirectory.dir("kotlinwrapper"))
+ destinationDirectory.set(project.layout.buildDirectory.dir("wrapperjars"))
from(kotlinDependencies)
into("neu-kotlin-libraries-wrapped")
}
+val mixinDependencyCollectionJar by tasks.creating(Zip::class) {
+ archiveFileName.set("mixin-libraries-wrapped.jar")
+ destinationDirectory.set(project.layout.buildDirectory.dir("wrapperjars"))
+ from(mixinRTDependencies)
+ into("neu-mixin-libraries-wrapped")
+}
tasks.register("includeBackupRepo") {
doLast {
@@ -257,7 +267,9 @@ tasks.shadowJar {
}
from(oneconfigQuarantineSourceSet.output)
from(kotlinDependencyCollectionJar)
+ from(mixinDependencyCollectionJar)
dependsOn(kotlinDependencyCollectionJar)
+ dependsOn(mixinDependencyCollectionJar)
fun relocate(name: String) = relocate(name, "io.github.moulberry.notenoughupdates.deps.$name")
relocate("com.mojang.brigadier")
relocate("io.github.moulberry.moulconfig")