Revert "feat(lom): initial NeoForge support (untested)"
This reverts commit ac475465ce
.
This commit is contained in:
parent
ac475465ce
commit
748a359fb6
|
@ -14,12 +14,4 @@ repositories {
|
|||
name = "Fabric"
|
||||
url = uri("https://maven.fabricmc.net/")
|
||||
}
|
||||
maven {
|
||||
name = "Architectury"
|
||||
url = uri("https://maven.architectury.dev/")
|
||||
}
|
||||
maven {
|
||||
name = "Forge"
|
||||
url = uri("https://files.minecraftforge.net/maven/")
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,8 +1,8 @@
|
|||
plugins {
|
||||
jf.`plugin-conventions`
|
||||
id("jf.plugin-conventions")
|
||||
}
|
||||
|
||||
dependencies {
|
||||
implementation("org.eclipse.jgit:org.eclipse.jgit:6.8.0.202311291450-r")
|
||||
implementation("org.eclipse.jgit:org.eclipse.jgit:6.5.0.202303070854-r")
|
||||
implementation("com.squareup:javapoet:1.13.0")
|
||||
}
|
|
@ -1,9 +1,9 @@
|
|||
plugins {
|
||||
jf.`plugin-conventions`
|
||||
id("jf.plugin-conventions")
|
||||
}
|
||||
|
||||
dependencies {
|
||||
api(projects.lom)
|
||||
implementation("com.modrinth.minotaur:Minotaur:2.8.7")
|
||||
api(project(":lom"))
|
||||
implementation("com.modrinth.minotaur:Minotaur:2.8.0")
|
||||
implementation("io.github.CDAGaming:CurseGradle:1.6.1")
|
||||
}
|
||||
|
|
|
@ -33,7 +33,7 @@ fun Project.legacyCheck(jfMod: JfModExtension) {
|
|||
}
|
||||
if (hasProperty("loader_version")) {
|
||||
logger.warn("Using loader_version is deprecated, please use the DSL")
|
||||
jfMod.fabricLoaderVersion.set(prop("loader_version"))
|
||||
jfMod.loaderVersion.set(prop("loader_version"))
|
||||
}
|
||||
if (hasProperty("yarn_mappings")) {
|
||||
logger.warn("Using yarn_mappings is deprecated, please use the DSL")
|
||||
|
|
|
@ -1,9 +1,9 @@
|
|||
plugins {
|
||||
jf.`plugin-conventions`
|
||||
id("jf.plugin-conventions")
|
||||
}
|
||||
|
||||
dependencies {
|
||||
api(projects.convention)
|
||||
api("dev.architectury.loom:dev.architectury.loom.gradle.plugin:1.5-SNAPSHOT")
|
||||
api(project(":convention"))
|
||||
api("net.fabricmc:fabric-loom:1.5-SNAPSHOT")
|
||||
api("com.github.johnrengelman:shadow:8.1.1")
|
||||
}
|
|
@ -16,22 +16,17 @@ interface LomExtension {
|
|||
}
|
||||
|
||||
val minecraftVersion: Property<String>
|
||||
val fabricLoaderVersion: Property<String>
|
||||
val neoforgeVersion: Property<String>
|
||||
val loaderVersion: Property<String>
|
||||
|
||||
fun check(proj: Project) {
|
||||
yarnBuild.finalizeValue()
|
||||
minecraftVersion.finalizeValue()
|
||||
fabricLoaderVersion.finalizeValue()
|
||||
neoforgeVersion.finalizeValue()
|
||||
require(!(fabricLoaderVersion.isPresent && neoforgeVersion.isPresent)) { "fabricLoaderVersion and forgeVersion are mutually exclusive" }
|
||||
require(fabricLoaderVersion.isPresent || neoforgeVersion.isPresent) { "fabricLoaderVersion or forgeVersion must be set" }
|
||||
loaderVersion.finalizeValue()
|
||||
}
|
||||
|
||||
fun copyFrom(ext: LomExtension) {
|
||||
yarnBuild.set(ext.yarnBuild)
|
||||
minecraftVersion.set(ext.minecraftVersion)
|
||||
fabricLoaderVersion.set(ext.fabricLoaderVersion)
|
||||
neoforgeVersion.set(ext.neoforgeVersion)
|
||||
loaderVersion.set(ext.loaderVersion)
|
||||
}
|
||||
}
|
|
@ -7,7 +7,7 @@ plugins {
|
|||
id("jf.java")
|
||||
idea
|
||||
`maven-publish`
|
||||
id("dev.architectury.loom")
|
||||
id("fabric-loom")
|
||||
id("com.github.johnrengelman.shadow")
|
||||
}
|
||||
|
||||
|
@ -17,7 +17,6 @@ val devlibs = project.layout.buildDirectory.dir("devlibs").get().asFile
|
|||
loom {
|
||||
runtimeOnlyLog4j.set(true)
|
||||
splitEnvironmentSourceSets()
|
||||
silentMojangMappingsLicense()
|
||||
}
|
||||
|
||||
// Create testmod source set with access to main and client classpaths
|
||||
|
@ -85,12 +84,8 @@ earlyAfterEvaluate {
|
|||
minecraft("com.mojang:minecraft:${args.minecraftVersion.get()}")
|
||||
if (args.yarnBuild.isPresent) mappings("net.fabricmc:yarn:${args.minecraftVersion.get()}+${args.yarnBuild.get()}:v2")
|
||||
else loom.officialMojangMappings()
|
||||
if (!hasProperty("loom.platform") || property("loom.platform") == "fabric") {
|
||||
modImplementation("net.fabricmc:fabric-loader:${args.fabricLoaderVersion.get()}")
|
||||
testImplementation("net.fabricmc:fabric-loader-junit:${args.fabricLoaderVersion.get()}")
|
||||
} else if (property("loom.platform") == "neoforge") {
|
||||
"neoForge"("net.minecraftforge:forge:${args.minecraftVersion.get()}-${args.neoforgeVersion.get()}")
|
||||
}
|
||||
modImplementation("net.fabricmc:fabric-loader:${args.loaderVersion.get()}")
|
||||
testImplementation("net.fabricmc:fabric-loader-junit:${args.loaderVersion.get()}")
|
||||
|
||||
testmodImplementation(sourceSets.main.get().output)
|
||||
testmodImplementation(sourceSets.client.get().output)
|
||||
|
@ -154,10 +149,9 @@ tasks.remapJar {
|
|||
|
||||
// fill in mod version
|
||||
tasks.processResources {
|
||||
filesMatching(listOf("fabric.mod.json", "META-INF/mods.toml")) {
|
||||
filesMatching("fabric.mod.json") {
|
||||
expand(mapOf("version" to project.versionS))
|
||||
}
|
||||
inputs.property("version", project.versionS)
|
||||
}
|
||||
|
||||
// publish sources jar and remapped jar without JiJ'd deps
|
||||
|
|
|
@ -3,5 +3,3 @@ rootProject.name = "scripts"
|
|||
include("lom")
|
||||
include("convention")
|
||||
include("jfmod")
|
||||
|
||||
enableFeaturePreview("TYPESAFE_PROJECT_ACCESSORS")
|
||||
|
|
Loading…
Reference in New Issue