@@ -3,7 +3,6 @@ import dev.architectury.pack200.java.Pack200Adapter
33
44plugins {
55 id " java"
6- id " com.github.johnrengelman.shadow" version " 7.1.2"
76 id " gg.essential.loom" version " 0.10.0.0"
87 id " dev.architectury.architectury-pack200" version " 0.1.3"
98 id ' org.jetbrains.kotlin.jvm' version ' 1.6.10'
@@ -44,19 +43,19 @@ loom {
4443 pack200Provider = new Pack200Adapter ()
4544 accessTransformer(file(" src/main/resources/crashpatch_at.cfg" ))
4645 mixinConfig(" mixin.crashpatch.json" )
46+ mixin. defaultRefmapName. set(" mixin.crashpatch.refmap.json" )
4747 }
4848}
4949
50- configurations {
51- // Creates an extra configuration that extends from `implementation` to be used later as the configuration that shades libraries
52- include
53- implementation. extendsFrom include
54- }
55-
5650repositories {
5751 maven { url ' https://repo.woverflow.cc/' }
5852}
5953
54+ configurations {
55+ include
56+ implementation. extendsFrom(include)
57+ }
58+
6059dependencies {
6160 minecraft(" com.mojang:minecraft:1.8.9" )
6261 mappings(" de.oceanlabs.mcp:mcp_stable:22-1.8.9" )
@@ -84,6 +83,16 @@ processResources {
8483}
8584
8685jar {
86+ dependsOn configurations. include
87+ from(configurations. include. collect { it. isDirectory() ? it : zipTree(it) }) {
88+ exclude ' club.sk1er.vigilance.example.ExampleMod' , ' dummyThing'
89+ def i = 0
90+ filesMatching(" META-INF/NOTICE*" ) { name = " $name . ${ i++} " }
91+ filesMatching(" META-INF/LICENSE*" ) { name = " $name . ${ i++} " }
92+ filesMatching(" META-INF/mods.toml" ) { name = " $name . ${ i++} " }
93+ filesMatching(" LICENSE*" ) { name = " $name . ${ i++} " }
94+ }
95+
8796 manifest. attributes(
8897 " ModSide" : " CLIENT" ,
8998 " TweakClass" : " gg.essential.loader.stage0.EssentialSetupTweaker" ,
@@ -93,36 +102,6 @@ jar {
93102 " FMLCorePlugin" : " cc.woverflow.wcore.tweaker.WCoreTweaker" ,
94103 " FMLCorePluginContainsFMLMod" : true
95104 )
96-
97- enabled = false
98- }
99-
100- tasks. jar. dependsOn tasks. shadowJar
101-
102- shadowJar {
103- archiveClassifier. set(" " )
104- configurations = [project. configurations. include]
105- duplicatesStrategy DuplicatesStrategy . EXCLUDE
106-
107- exclude " LICENSE.md"
108- exclude " pack.mcmeta"
109- exclude " dummyThing"
110- exclude " **/module-info.class"
111- exclude " *.so"
112- exclude " *.dylib"
113- exclude " *.dll"
114- exclude " *.jnilib"
115- exclude " ibxm/**"
116- exclude " com/jcraft/**"
117- exclude " org/lwjgl/**"
118- exclude " net/java/**"
119-
120- exclude " META-INF/proguard/**"
121- exclude " META-INF/maven/**"
122- exclude " META-INF/versions/**"
123- exclude " META-INF/com.android.tools/**"
124-
125- exclude " fabric.mod.json"
126105}
127106
128107sourceSets {
0 commit comments