File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1+ plugins {
2+ java
3+ }
4+
5+ afterEvaluate {
6+ tasks {
7+ named<Task >(" jpackageImage" ) {
8+ dependsOn(" build" )
9+
10+ doLast {
11+ val jarsToDelete = listOf (
12+ " annotations*.jar" ,
13+ " antlr4-runtime*.jar" ,
14+ " bigint*.jar" ,
15+ " checker-qual*.jar" ,
16+ " commons-compiler*.jar" ,
17+ " error_prone_annotations*.jar" ,
18+ " failureaccess*.jar" ,
19+ " guava*.jar" ,
20+ " j2objc-annotations*.jar" ,
21+ " janino*.jar" ,
22+ " jsr305*.jar" ,
23+ " jts-core*.jar" ,
24+ " kotlin-stdlib*.jar" ,
25+ " listenablefuture*.jar"
26+ )
27+ jarsToDelete.forEach { jar ->
28+ delete(fileTree(layout.buildDirectory.dir(" jpackage/lightzone/lib/app" )).matching { include(jar) })
29+ }
30+ }
31+ }
32+ }
33+ }
Original file line number Diff line number Diff line change @@ -4,6 +4,7 @@ import java.time.format.DateTimeFormatter
44plugins {
55 kotlin(" jvm" )
66 id(" lightzone.java-conventions" )
7+ id(" lightzone.remove-unused" )
78 id(" org.beryx.runtime" )
89}
910dependencies {
@@ -21,10 +22,7 @@ tasks {
2122 }
2223 jpackage {
2324 dependsOn(" jpackageImage" )
24- }
25- jpackageImage {
26- dependsOn(" build" )
27- doLast {
25+ doFirst {
2826 copy {
2927 from(" products/" )
3028 include(" dcraw_lz" )
@@ -45,26 +43,6 @@ tasks {
4543 include(" **" )
4644 into(layout.buildDirectory.dir(" jpackage/lightzone/share/icons" ))
4745 }
48-
49- val jarsToDelete = listOf (
50- " annotations*.jar" ,
51- " antlr4-runtime*.jar" ,
52- " bigint*.jar" ,
53- " checker-qual*.jar" ,
54- " commons-compiler*.jar" ,
55- " error_prone_annotations*.jar" ,
56- " failureaccess*.jar" ,
57- " guava*.jar" ,
58- " j2objc-annotations*.jar" ,
59- " janino*.jar" ,
60- " jsr305*.jar" ,
61- " jts-core*.jar" ,
62- " kotlin-stdlib*.jar" ,
63- " listenablefuture*.jar"
64- )
65- jarsToDelete.forEach { jar ->
66- delete(fileTree(layout.buildDirectory.dir(" jpackage/lightzone/lib/app" )).matching { include(jar) })
67- }
6846 }
6947 }
7048}
Original file line number Diff line number Diff line change @@ -4,6 +4,7 @@ import java.time.format.DateTimeFormatter
44plugins {
55 kotlin(" jvm" )
66 id(" lightzone.java-conventions" )
7+ id(" lightzone.remove-unused" )
78 id(" org.beryx.runtime" )
89}
910dependencies {
@@ -23,7 +24,7 @@ tasks {
2324 commandLine(" make" , " -C" , " help" )
2425 }
2526 jpackage {
26- dependsOn(" build " , " helpFiles" )
27+ dependsOn(" jpackageImage " , " helpFiles" )
2728 doFirst {
2829 copy {
2930 from(" products/" )
@@ -39,26 +40,6 @@ tasks {
3940 include(" *.icns" )
4041 into(layout.buildDirectory.dir(" jpackage/LightZone.app/Contents/Resources" ))
4142 }
42-
43- val jarsToDelete = listOf (
44- " annotations*.jar" ,
45- " antlr4-runtime*.jar" ,
46- " bigint*.jar" ,
47- " checker-qual*.jar" ,
48- " commons-compiler*.jar" ,
49- " error_prone_annotations*.jar" ,
50- " failureaccess*.jar" ,
51- " guava*.jar" ,
52- " j2objc-annotations*.jar" ,
53- " janino*.jar" ,
54- " jsr305*.jar" ,
55- " jts-core*.jar" ,
56- " kotlin-stdlib*.jar" ,
57- " listenablefuture*.jar"
58- )
59- jarsToDelete.forEach { jar ->
60- delete(fileTree(layout.buildDirectory.dir(" jpackage/lightzone/lib/app" )).matching { include(jar) })
61- }
6243 }
6344 doLast {
6445 val versionSuffix = " -${project.version.toString().substringBefore(" b" )} .dmg"
Original file line number Diff line number Diff line change @@ -4,6 +4,7 @@ import java.time.format.DateTimeFormatter
44plugins {
55 kotlin(" jvm" )
66 id(" lightzone.java-conventions" )
7+ id(" lightzone.remove-unused" )
78 id(" org.beryx.runtime" )
89}
910dependencies {
@@ -24,7 +25,7 @@ tasks {
2425 commandLine(" make" , " -C" , " help" )
2526 }
2627 jpackage {
27- dependsOn(" build " , " helpFiles" )
28+ dependsOn(" jpackageImage " , " helpFiles" )
2829 doFirst {
2930 copy {
3031 from(" products/" )
@@ -38,26 +39,6 @@ tasks {
3839 include(" *.dll" )
3940 into(layout.buildDirectory.dir(" jpackage/LightZone/app" ))
4041 }
41-
42- val jarsToDelete = listOf (
43- " annotations*.jar" ,
44- " antlr4-runtime*.jar" ,
45- " bigint*.jar" ,
46- " checker-qual*.jar" ,
47- " commons-compiler*.jar" ,
48- " error_prone_annotations*.jar" ,
49- " failureaccess*.jar" ,
50- " guava*.jar" ,
51- " j2objc-annotations*.jar" ,
52- " janino*.jar" ,
53- " jsr305*.jar" ,
54- " jts-core*.jar" ,
55- " kotlin-stdlib*.jar" ,
56- " listenablefuture*.jar"
57- )
58- jarsToDelete.forEach { jar ->
59- delete(fileTree(layout.buildDirectory.dir(" jpackage/lightzone/lib/app" )).matching { include(jar) })
60- }
6142 }
6243 doLast {
6344 val versionSuffix = " -${project.version} .msi"
You can’t perform that action at this time.
0 commit comments