diff --git a/build.gradle b/build.gradle index 4f75c67e..da7b1db6 100644 --- a/build.gradle +++ b/build.gradle @@ -19,7 +19,7 @@ def getGitCommit = { -> return stdout.toString().trim() } -Aw2AtTask.configureDefault( +def aw2at = Aw2AtTask.configureDefault( getProject(), layout.projectDirectory.file("src/main/resources/moonrise.accesswidener").getAsFile(), sourceSets.main @@ -28,10 +28,7 @@ Aw2AtTask.configureDefault( neoForge { neoFormVersion = "1.21.3-20241023.131943" validateAccessTransformers = true -} - -tasks.named("createMinecraftArtifacts") { - dependsOn("copyAt") + accessTransformers.files.setFrom(aw2at.flatMap { t -> t.getOutputFile() }) } dependencies { diff --git a/neoforge/build.gradle b/neoforge/build.gradle index 417a43c3..f04449fb 100644 --- a/neoforge/build.gradle +++ b/neoforge/build.gradle @@ -14,7 +14,7 @@ repositories { } } -Aw2AtTask.configureDefault( +def aw2at = Aw2AtTask.configureDefault( getProject(), rootProject.layout.projectDirectory.file("src/main/resources/moonrise.accesswidener").getAsFile(), sourceSets.main @@ -23,6 +23,7 @@ Aw2AtTask.configureDefault( neoForge { version = rootProject.neoforge_version validateAccessTransformers = true + accessTransformers.files.setFrom(aw2at.flatMap { t -> t.getOutputFile() }) runs { client { client() @@ -35,10 +36,6 @@ neoForge { } } -tasks.named("createMinecraftArtifacts") { - dependsOn("copyAt") -} - configurations.implementation { extendsFrom(configurations.shadow) }