Cleaned some stuff on the gradle
This commit is contained in:
+6
-35
@@ -88,23 +88,6 @@ forgix {
|
||||
removeDuplicate "com.seibel.lod.core"
|
||||
}
|
||||
|
||||
def useManifold(p) {
|
||||
// def enableManifold = true
|
||||
// // Only add manifold to forge when this is disabled
|
||||
// // if manifold is enabled when forge is running runtimeClasspathCopy
|
||||
// println gradle.taskGraph.allTasks
|
||||
// gradle.taskGraph.whenReady { taskGraph ->
|
||||
// println taskGraph.allTasks
|
||||
// taskGraph.allTasks.each { task ->
|
||||
// println task.path
|
||||
// if (task.path.contains("Srg") || task.path.contains("runtimeClasspathCopy") || task.path.contains(":forge"))
|
||||
// enableManifold = false
|
||||
// }
|
||||
// }
|
||||
// return enableManifold
|
||||
return p != project(":forge")
|
||||
}
|
||||
|
||||
subprojects { p ->
|
||||
// Does the same as "p == project(":common") || p == project(":fabric") || p == project(":quilt") || p == project(":forge")"
|
||||
// Useful later on so we dont have duplicated code
|
||||
@@ -113,7 +96,7 @@ subprojects { p ->
|
||||
|
||||
// Apply plugins
|
||||
apply plugin: "java"
|
||||
if (isMinecraftSubProject && useManifold(p))
|
||||
if (isMinecraftSubProject)
|
||||
apply plugin: "systems.manifold.manifold-gradle-plugin"
|
||||
apply plugin: "com.github.johnrengelman.shadow"
|
||||
// apply plugin: "org.spongepowered.gradle.vanilla" // Provides minecraft libraries
|
||||
@@ -123,10 +106,9 @@ subprojects { p ->
|
||||
|
||||
|
||||
// Set the manifold version (may not be required tough)
|
||||
if (useManifold(p))
|
||||
manifold {
|
||||
manifoldVersion = rootProject.manifold_version
|
||||
}
|
||||
manifold {
|
||||
manifoldVersion = rootProject.manifold_version
|
||||
}
|
||||
|
||||
|
||||
// set up custom configurations (configurations are a way to handle dependencies)
|
||||
@@ -165,7 +147,7 @@ subprojects { p ->
|
||||
|
||||
|
||||
// Manifold
|
||||
if (isMinecraftSubProject && useManifold(p))
|
||||
if (isMinecraftSubProject)
|
||||
annotationProcessor("systems.manifold:manifold-preprocessor:${rootProject.manifold_version}")
|
||||
|
||||
// Log4j
|
||||
@@ -427,18 +409,7 @@ allprojects { p ->
|
||||
tasks.withType(JavaCompile) {
|
||||
if (isMinecraftSubProject) {
|
||||
options.release = rootProject.java_version as Integer
|
||||
|
||||
// def enableManifold = false
|
||||
// // Only add manifold to forge when this is disabled
|
||||
// // if manifold is enabled when forge is running runtimeClasspathCopy
|
||||
// gradle.taskGraph.whenReady { taskGraph ->
|
||||
// taskGraph.allTasks.each { task ->
|
||||
// if (task.path.contains("compileJava"))
|
||||
// enableManifold = true
|
||||
// }
|
||||
// }
|
||||
if (useManifold(p))
|
||||
options.compilerArgs += ['-Xplugin:Manifold']
|
||||
options.compilerArgs += ['-Xplugin:Manifold']
|
||||
} else {
|
||||
options.release = 8; // Core & Api should use Java 8 no matter what
|
||||
//options.release = rootProject.java_version as Integer // But if minecraft
|
||||
|
||||
+1
-1
Submodule coreSubProjects updated: c44c501cd8...1234e47f55
@@ -115,6 +115,7 @@ dependencies {
|
||||
common(project(path: ":common")) { transitive false }
|
||||
shadowCommon(project(path: ":common")) { transitive false }
|
||||
// shadowCommon(project(path: ":common"), configuration: "transformProductionFabric") { transitive false } // FIXME
|
||||
// TODO: These exist in the main build.gradle so fix shadow there
|
||||
shadowMe(project(path: ":core")) { transitive false }
|
||||
shadowMe(project(path: ":api")) { transitive false }
|
||||
}
|
||||
|
||||
+3
-3
@@ -30,7 +30,7 @@ def loadProperties() {
|
||||
def mcVersion = ""
|
||||
def mcVers = fileTree("versionProperties").files.name // Get all the files in "versionProperties"
|
||||
for (int i = 0; i < mcVers.size(); i++) {
|
||||
mcVers[i] = mcVers[i].replaceAll(".properties", "") // As we are getting the file names, we should remove the ".properties" at the end to get the versions
|
||||
mcVers[i] = mcVers[i].replaceAll("\\.properties", "") // As we are getting the file names, we should remove the ".properties" at the end to get the versions
|
||||
}
|
||||
|
||||
mcVers.sort() // Sort so it always goes from oldest to newest
|
||||
@@ -79,8 +79,8 @@ if (gradle.builds_for.contains("fabric"))
|
||||
include("fabric")
|
||||
if (gradle.builds_for.contains("quilt"))
|
||||
include("quilt") // Just put this here for once we need it ;)
|
||||
if (gradle.builds_for.contains("forge"))
|
||||
include("forge")
|
||||
//if (gradle.builds_for.contains("forge"))
|
||||
// include("forge")
|
||||
|
||||
|
||||
rootProject.name = "DistantHorizons"
|
||||
|
||||
Reference in New Issue
Block a user