fix neoforg

This commit is contained in:
Ran-Mewo
2026-03-30 17:06:51 +11:00
parent 0647bdbab3
commit 2674b945bb
3 changed files with 5 additions and 4 deletions
+3 -2
View File
@@ -334,14 +334,15 @@ if (isNotCommonProject) {
} }
// Make run tasks use the shadow jar so relocated deps (NightConfig, etc.) work in dev. // Make run tasks use the shadow jar so relocated deps (NightConfig, etc.) work in dev.
// Without this, NeoForge's bundled NightConfig 3.8.x conflicts with DH's 3.6.6. def shadowedFiles = configurations.shadowMe.resolve().collect { it.name }.toSet() // Filter out jars that are already bundled+relocated in the shadow jar to avoid classpath conflicts (e.g. DH's NightConfig vs NeoForge's).
tasks.withType(JavaExec).configureEach { runTask -> tasks.withType(JavaExec).configureEach { runTask ->
dependsOn(shadowJar) dependsOn(shadowJar)
classpath = files(shadowJar.archiveFile) + classpath.filter { file -> classpath = files(shadowJar.archiveFile) + classpath.filter { file ->
!file.path.contains(project.buildDir.path) && !file.path.contains(project.buildDir.path) &&
!file.path.contains("core${File.separator}build") && !file.path.contains("core${File.separator}build") &&
!file.path.contains("api${File.separator}build") && !file.path.contains("api${File.separator}build") &&
!file.path.contains("common${File.separator}build") !file.path.contains("common${File.separator}build") &&
!shadowedFiles.contains(file.name)
} }
} }
} }
+1 -1
View File
@@ -20,7 +20,7 @@ mod_discord=https://discord.gg/xAB8G4cENx
# Global Plugin Versions # Global Plugin Versions
manifold_version=2026.1.6 manifold_version=2026.1.6
# 2023.1.17 can be used if there are mystery Java compiler issues # 2023.1.17 can be used if there are mystery Java compiler issues
nightconfig_version=3.6.6 nightconfig_version=3.8.3
lz4_version=1.8.0 lz4_version=1.8.0
xz_version=1.9 xz_version=1.9
zstd_version=1.5.7-6 zstd_version=1.5.7-6