Distribution library output clash

I am using the distTar target successfully on most of the project I have with Gradle for generating a tar with the app and its dependencies and start scripts. Unfortunately in one case I got the following problem:

Using java, application and distribution plugin I have the following dependencies on my project:


Development and even gradle run works fine. But the distTar is not considering all the files. It is copying to application-name/lib/artifact-name-1.0.jar twice, so one of the files is lost on the target tar.

What I need is a way to output the dependency jar name using the group together with the artifact name and version, so the clash can be avoided. Is such behavior possible?

Before anybody asks, indeed I did a google search, looked at the docs and etc.

Thanks in advance!