1- import com.github.jengelman.gradle.plugins.shadow.transformers.PreserveFirstFoundResourceTransformer
21import org.apache.tools.ant.taskdefs.condition.Os
32
43plugins {
@@ -75,13 +74,11 @@ tasks.register('jre') {
7574
7675 def output = providers. exec {
7776 ignoreExitValue = true
78- commandLine = [
79- jlink. toString(), ' -v' ,
80- * (inputs. properties[' options' ] as List ),
81- ' --module-path' , jmods. toString(),
82- ' --add-modules' , (inputs. properties[' modules' ] as List ). join(' ,' ),
83- ' --output' , jreOutputDir. get(). toString()
84- ]
77+ commandLine = [jlink. toString(), ' -v' ,
78+ * (inputs. properties[' options' ] as List ),
79+ ' --module-path' , jmods. toString(),
80+ ' --add-modules' , (inputs. properties[' modules' ] as List ). join(' ,' ),
81+ ' --output' , jreOutputDir. get(). toString()]
8582 }
8683
8784 def result = output. result. get()
@@ -131,9 +128,10 @@ application {
131128shadowJar {
132129 duplicatesStrategy = DuplicatesStrategy . INCLUDE
133130 mergeServiceFiles()
131+ failOnDuplicateEntries = true
134132
135- transform( PreserveFirstFoundResourceTransformer ) {
136- resources . addAll(
133+ dependencies {
134+ exclude( ' dist_webp_binaries/ ' ,
137135 ' META-INF/LICENSE' ,
138136 ' META-INF/LICENSE.txt' ,
139137 ' META-INF/NOTICE' ,
@@ -142,13 +140,6 @@ shadowJar {
142140 ' license/LICENSE.dom-documentation.txt' ,
143141 ' license/LICENSE.dom-software.txt' ,
144142 ' license/NOTICE' ,
145- ' license/README.dom.txt'
146- )
147- }
148-
149- failOnDuplicateEntries = true
150-
151- dependencies {
152- exclude(' dist_webp_binaries/' )
143+ ' license/README.dom.txt' )
153144 }
154145}
0 commit comments