-
-
Notifications
You must be signed in to change notification settings - Fork 424
Non-relocating shadow jars should use Bundling.EMBEDDED #1767
Copy link
Copy link
Labels
Description
Description
The shadowRuntimeElements is published with the publication using the Bundling.SHADOWED attribute. In Gradle's documentation for Bundling:
externalindicates that transitive dependencies are themselves component jarsembeddedindicates that transitive dependencies have been included inside the component jar, without modifying their packagesshadowedindicates that transitive dependencies have been included inside the component jar, under different packages to prevent conflicts
With that in mind, I think it would be a good idea to check, after evaluation, if the shadowJar task is relocating dependencies. If it is, use SHADOWED. And if it isn't, use EMBEDDED. This could be especially important since Shadow's default behavior is to not relocate packages.
Reactions are currently unavailable