1
0
mirror of https://github.com/SquidDev-CC/CC-Tweaked synced 2025-09-02 18:37:55 +00:00

More Gradle cleanup

Mostly configuration cache support. And an aborted attempt at updating
spotless, which just resulted in a bunch of ktlint issues :/.
This commit is contained in:
Jonathan Coates
2025-01-13 21:54:20 +00:00
parent ef0af67e96
commit 8204944b5f
16 changed files with 87 additions and 145 deletions

View File

@@ -61,6 +61,16 @@ configurations {
include { extendsFrom(includeRuntimeOnly.get(), includeImplementation.get()) }
runtimeOnly { extendsFrom(includeRuntimeOnly.get()) }
implementation { extendsFrom(includeImplementation.get()) }
// Declare a configuration for projects which are on the compile and runtime classpath, but not treated as
// dependencies. This is used for our local projects.
val localImplementation by registering {
isCanBeResolved = false
isCanBeConsumed = false
isVisible = false
}
compileClasspath { extendsFrom(localImplementation.get()) }
runtimeClasspath { extendsFrom(localImplementation.get()) }
}
dependencies {
@@ -90,9 +100,9 @@ dependencies {
"includeImplementation"(libs.nightConfig.toml)
// Pull in our other projects. See comments in MinecraftConfigurations on this nastiness.
api(commonClasses(project(":fabric-api"))) { cct.exclude(this) }
clientApi(clientClasses(project(":fabric-api"))) { cct.exclude(this) }
implementation(project(":core")) { cct.exclude(this) }
"localImplementation"(project(":core"))
"localImplementation"(commonClasses(project(":fabric-api")))
clientImplementation(clientClasses(project(":fabric-api")))
annotationProcessorEverywhere(libs.autoService)
@@ -210,11 +220,9 @@ loom {
}
tasks.processResources {
inputs.property("version", modVersion)
var props = mapOf("version" to modVersion)
filesMatching("fabric.mod.json") {
expand(mapOf("version" to modVersion))
}
filesMatching("fabric.mod.json") { expand(props) }
}
tasks.jar {