Archives configuration & default artifacts behavior/documentation

I recently ran into some issues regarding the artifacts in the archives configuration.
Related topics:

What I found is this:
BasePlugin configures a DefaultArtifactPublicationSet to add default artifacts to the archives configuration - such as jar, ear, and war archives (source lines 154 - 166).
DefaultArtifactPublicationSet subsequently adds all artifacts that are not of type jar, ear, or war to the artifacts of the archives configuration (source).

This effectively adds all artifacts of all configurations to the archives configuration, unless they are Jar, Ear, or War.
Is this intended? If it is, I would expect the documentation to state that explicitly - which I didn’t find anywhere.

1 Like