From 6fe6a4c9884fd48fe190de8a7b8a4626410553a1 Mon Sep 17 00:00:00 2001 From: soloturn Date: Sat, 12 Feb 2022 18:49:30 +0100 Subject: [PATCH] gradle, reorder to permit fat jar and features --- build.gradle.kts | 28 +++++++++++----------------- 1 file changed, 11 insertions(+), 17 deletions(-) diff --git a/build.gradle.kts b/build.gradle.kts index c7221cda7..e73e47908 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -12,9 +12,12 @@ plugins { signing } -repositories { - mavenLocal() - mavenCentral() +group = "net.sourceforge.plantuml" +description = "PlantUML" + +java { + withSourcesJar() + withJavadocJar() } dependencies { @@ -24,12 +27,9 @@ dependencies { testImplementation("org.scilab.forge:jlatexmath:1.0.7") } -group = "net.sourceforge.plantuml" -description = "PlantUML" - -java { - withSourcesJar() - withJavadocJar() +repositories { + mavenLocal() + mavenCentral() } sourceSets { @@ -72,18 +72,12 @@ tasks.withType().configureEach { attributes["Build-Jdk-Spec"] = System.getProperty("java.specification.version") from("manifest.txt") } - - dependsOn(configurations.runtimeClasspath) - from({ - configurations.runtimeClasspath.get().filter { it.name.endsWith("jar") }.map { zipTree(it) } - }) - - // source sets for java and resources are on "src", only put once into the jar - duplicatesStrategy = org.gradle.api.file.DuplicatesStrategy.EXCLUDE from("skin") { into("skin") } from("stdlib") { into("stdlib") } from("svg") { into("svg") } from("themes") { into("themes") } + // source sets for java and resources are on "src", only put once into the jar + duplicatesStrategy = DuplicatesStrategy.EXCLUDE } publishing {