1
0
mirror of https://github.com/SquidDev-CC/CC-Tweaked synced 2025-10-25 02:47:39 +00:00

Fix a couple of packaging issues

- Fix client classes not being included in Forge.
 - Only remap Nettty's HTTP classes, not all of them. This feels a
   little more error prone - maybe we should jar-in-jar this in the
   future.
 - Use the correct refmaps on Forge.
 - Prevent the Fabric jar pulling in some other mods.

Closes #1247
This commit is contained in:
Jonathan Coates
2022-12-12 20:28:18 +00:00
parent 18fbd96c10
commit 06163e4f25
5 changed files with 17 additions and 15 deletions

View File

@@ -115,8 +115,8 @@ minecraft {
}
mixin {
add(sourceSets.main.get(), "computercraft.mixins.refmap.json")
add(sourceSets.client.get(), "computercraft-client.mixins.refmap.json")
add(sourceSets.main.get(), "computercraft.refmap.json")
add(sourceSets.client.get(), "client-computercraft.refmap.json")
config("computercraft.mixins.json")
config("computercraft-client.mixins.json")
@@ -133,6 +133,7 @@ configurations {
dependencies {
annotationProcessor("org.spongepowered:mixin:0.8.5-SQUID:processor")
clientAnnotationProcessor("org.spongepowered:mixin:0.8.5-SQUID:processor")
compileOnly(libs.jetbrainsAnnotations)
annotationProcessorEverywhere(libs.autoService)
@@ -219,13 +220,15 @@ tasks.shadowJar {
finalizedBy("reobfShadowJar")
archiveClassifier.set("")
from(sourceSets.client.get().output)
dependencies {
include(dependency("cc.tweaked:"))
include(dependency(libs.cobalt.get()))
include(dependency(libs.netty.http.get()))
}
relocate("org.squiddev.cobalt", "cc.tweaked.internal.cobalt")
relocate("io.netty.handler", "cc.tweaked.internal.netty")
relocate("io.netty.handler.codec.http", "cc.tweaked.internal.netty.codec.http")
minimize()
}

View File

@@ -1,13 +1,13 @@
{
"minVersion": "0.8",
"required": true,
"compatibilityLevel": "JAVA_17",
"refmap": "computercraft.mixins.refmap.json",
"package": "dan200.computercraft.mixin.client",
"minVersion": "0.8",
"compatibilityLevel": "JAVA_17",
"injectors": {
"defaultRequire": 1
},
"client": [
"BlockRenderDispatcherMixin"
],
"injectors": {
"defaultRequire": 1
}
"refmap": "client-computercraft.refmap.json"
}