This commit is contained in:
+24
-7
@@ -1,11 +1,10 @@
|
||||
// Root build for the Architectury multiloader (Fabric / Forge / NeoForge).
|
||||
// Follows the standard Architectury 1.7.x example-template layout. Target MC
|
||||
// version is driven by gradle.properties (minecraft_version + the *_version
|
||||
// props). Default is 1.21.1; switch to 1.20.1 by editing gradle.properties and
|
||||
// swapping the version-specific mixin sources (see MULTILOADER.md).
|
||||
// Root build for the Architectury multiloader (Fabric / Forge).
|
||||
// Target MC version is driven by gradle.properties (minecraft_version + the
|
||||
// *_version props). This branch targets Minecraft 1.20.1 / Java 17.
|
||||
plugins {
|
||||
id "architectury-plugin" version "3.4-SNAPSHOT"
|
||||
id "dev.architectury.loom" version "1.7-SNAPSHOT" apply false
|
||||
id "base"
|
||||
id "architectury-plugin" version "3.4.164"
|
||||
id "dev.architectury.loom" version "1.7.435" apply false
|
||||
id "com.gradleup.shadow" version "8.3.5" apply false
|
||||
}
|
||||
|
||||
@@ -58,3 +57,21 @@ subprojects {
|
||||
options.release = javaVer
|
||||
}
|
||||
}
|
||||
|
||||
def runtimePlatforms = rootProject.enabled_platforms.split(",").collect { it.trim() }.findAll { !it.isEmpty() }
|
||||
|
||||
tasks.register("collectRuntimeJars", Copy) {
|
||||
into layout.buildDirectory.dir("libs")
|
||||
doFirst {
|
||||
delete(layout.buildDirectory.dir("libs"))
|
||||
}
|
||||
runtimePlatforms.each { platform ->
|
||||
def remap = project(":${platform}").tasks.named("remapJar")
|
||||
dependsOn remap
|
||||
from(remap.flatMap { it.archiveFile })
|
||||
}
|
||||
}
|
||||
|
||||
tasks.named("build") {
|
||||
dependsOn tasks.named("collectRuntimeJars")
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user