I’m trying to have Gradle upload a “Bills of Materials” POM file to Artifactory.
I already have a working project which deploys a POM file and a dummy jar file. However this doesn’t work because the “packaging” inside the POM file is set to “jar” (because I apply the “java” plugin).
I tried to force the packaging to “pom” by using the available callbacks but then the upload to Artifactory fails with an HTTP 409 (Conflict) error. I suppose this is caused because I upload a jar file but the packaging of the associated POM file is set to “pom” (instead of jar) so Artifactory complains.
I tried to stop generating the jar file but in this case nothing gets uploaded.
What’s the theory for having a Gradle build publish a unique POM file to Artifactory ? It seems that using the ‘maven’ plugin is not the way to go.
Any piece of advice would be greatly appreciated !