]> git.lizzy.rs Git - LightOverlay.git/blobdiff - fabric/build.gradle
Multi-loader common module build
[LightOverlay.git] / fabric / build.gradle
index 6cd73c20de7617dc0800015279cce0a3c8ecbe82..9b8058da031f18d2f18f37aa6d96e6f7dae00419 100755 (executable)
@@ -1,5 +1,6 @@
 plugins {
-    id("fabric-loom") version "0.4-SNAPSHOT"
+    id "fabric-loom"
+    id "com.github.johnrengelman.shadow" version "5.0.0"
 }
 
 minecraft {
@@ -13,14 +14,13 @@ processResources {
     inputs.property "version", project.version
 }
 
-repositories {
-    jcenter()
-    maven { url "https://dl.bintray.com/shedaniel/legacy-yarn-updated" }
+configurations {
+    shadow
 }
 
 dependencies {
-    minecraft "com.mojang:minecraft:${rootProject.fabric_minecraft_version}"
-    mappings "me.shedaniel:legacy-yarn:${rootProject.yarn_build}:v2"
+    minecraft "com.mojang:minecraft:${rootProject.architect.minecraft}"
+    mappings minecraft.officialMojangMappings()
     modCompile "net.fabricmc:fabric-loader:${rootProject.fabric_loader_version}"
 
     modCompile "net.fabricmc.fabric-api:fabric-api:${rootProject.fabric_api_version}"
@@ -39,4 +39,23 @@ dependencies {
     include("me.shedaniel.cloth:config-2:${rootProject.cloth_config_version}") {
         transitive = false
     }
+
+    compile(project(":common")) {
+        transitive = false
+    }
+    shadow(project(":common")) {
+        transitive = false
+    }
 }
+
+shadowJar {
+    relocate "me.shedaniel.lightoverlay.common", "me.shedaniel.lightoverlay.common.fabric"
+
+    configurations = [project.configurations.shadow]
+    classifier "shadow"
+}
+
+remapJar {
+    dependsOn(shadowJar)
+    input.set(shadowJar.archivePath)
+}
\ No newline at end of file