import net.fabricmc.loom.task.RemapJarTask plugins { id 'fabric-loom' version '1.7-SNAPSHOT' id "com.github.johnrengelman.shadow" version "8.1.1" } archivesBaseName = 'animalrp' repositories { mavenCentral() maven { url 'https://maven.fabricmc.net/' } maven { url "https://maven.nucleoid.xyz/" name "Nucleoid" } } dependencies { minecraft "com.mojang:minecraft:${project.minecraft_version}" mappings "net.fabricmc:yarn:${project.yarn_mappings}:v2" modImplementation "net.fabricmc:fabric-loader:${project.loader_version}" modImplementation "net.fabricmc.fabric-api:fabric-api:${project.fabric_version}" include(modImplementation("eu.pb4:placeholder-api:2.4.1+1.21")) implementation project(':animalrp-common') } processResources { inputs.property 'version', project.mod_version filesMatching('**/fabric.mod.json') { expand 'version': project.mod_version } } shadowJar { archiveFileName = "animalrpfabric-${project.mod_version}-dev.jar" dependencies { exclude('net.fabricmc:.*') include(dependency('ovh.sad:.*')) include(dependency('ovh.sad.animalrp:.*')) // We don't want to include the mappings in the jar do we? exclude '/mappings/*' } } task remappedShadowJar(type: RemapJarTask) { dependsOn tasks.shadowJar input = tasks.shadowJar.archiveFile addNestedDependencies = true archiveFileName = "AnimalRP-Fabric-${project.mod_version}.jar" } tasks.assemble.dependsOn tasks.remappedShadowJar artifacts { archives remappedShadowJar shadow shadowJar }