With the new <DSL for launching JVM apps>, is ther...
# gradle
c
With the new DSL for launching JVM apps, is there a way to run proguard on the jar for launch and distribution? Looking at the DefaultKotlinJvmBinariesDsl source, I’m not sure the necessary hooks are currently public (e.g.
jarTask
) although I wanted to see if someone else has explored this. I’ve got a working series of custom tasks for building a fat jar, then a proguard jar from the fat jar, and was curious if this new DSL could simplify things down.
t
for launch you may try
finalizedBy(proguardTask)
approach on
Jar
task
or create a separate `JavaExec`/`Distribution` entries based on the base one created by KGP
c
If I try
finalizedBy(proguardTask)
, what task specifically should I be finalizing? Is this something where I need to do
tasks.named("X")
?
t
I would say
Jar
task. Though there is no API to get either task name or
TaskProvider
sad panda
c
So maybe I should file a YouTrack feature request?