From c0b02ea7091b5f8ff278634dc7d701bf91b8ae82 Mon Sep 17 00:00:00 2001 From: Jason Penilla <11360596+jpenilla@users.noreply.github.com> Date: Sun, 1 Dec 2024 20:01:34 -0700 Subject: [PATCH] fix jarjar being missing from final neoforge jar --- neoforge/build.gradle | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) diff --git a/neoforge/build.gradle b/neoforge/build.gradle index bc602139..4d0efb9a 100644 --- a/neoforge/build.gradle +++ b/neoforge/build.gradle @@ -66,11 +66,11 @@ tasks.processResources { } tasks.jar { - archiveClassifier = "slim" + archiveClassifier = "dev" } tasks.shadowJar { - archiveClassifier = "" + archiveClassifier = "dev-all" destinationDirectory = layout.buildDirectory.dir("libs") configurations = [project.configurations.shadow] relocate 'ca.spottedleaf.concurrentutil', 'ca.spottedleaf.moonrise.libs.ca.spottedleaf.concurrentutil' @@ -78,12 +78,19 @@ tasks.shadowJar { relocate 'org.yaml.snakeyaml', 'ca.spottedleaf.moonrise.libs.org.yaml.snakeyaml' } +tasks.register("productionJar", Zip.class) { + archiveClassifier = "" + destinationDirectory = layout.buildDirectory.dir("libs") + from(tasks.jarJar) + from(zipTree(tasks.shadowJar.archiveFile)) +} + tasks.assemble { - dependsOn tasks.shadowJar + dependsOn tasks.productionJar } publishMods { - file = shadowJar.archiveFile + file = productionJar.archiveFile modLoaders = ["neoforge"] modrinth {