From 3d70100119d27bb026be7ec7de6dd5ceeedb86a1 Mon Sep 17 00:00:00 2001 From: Telesphoreo Date: Sat, 2 Dec 2023 01:17:27 -0600 Subject: [PATCH] Yes, there is --- build.gradle.kts | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) diff --git a/build.gradle.kts b/build.gradle.kts index f84d7fb..79754b7 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -72,15 +72,19 @@ subprojects { } tasks.clean { - // Is there any way to not need to specify each subproject? - dependsOn(":server:clean") - dependsOn(":proxy:clean") + dependsOn(subprojects.map { + it.project.tasks.clean + }) } tasks.create("copyJars") { + dependsOn(tasks.jar) duplicatesStrategy = DuplicatesStrategy.EXCLUDE - // Is there any way to not need to specify each subproject? - from(tasks.getByPath(":server:shadowJar")) - from(tasks.getByPath(":proxy:jar")) + from(subprojects.map { + it.project.tasks.shadowJar + }) + from(subprojects.map { + it.project.tasks.jar + }) into(file("build/libs")) } \ No newline at end of file