Hello,
My project consist of multiple subprojects. Each of these outputs a jar. For deployment I need to sign those jar and collect all of them. So what I did is defining a signJar task that does its stuff to create a new signed jar and I used the sharing task output as described here: Sharing outputs between projects to pass all the jars to the root project.
Now I have a problem in that running gradle build
, the signJar tasks are always executed due to being added as
artifacts {
add("signedJar", signedJar)
}
in each subproject.
Is there a way to have those created only when publishing and not when calling the build
task?
Thanks!