I ran into the issue described in “http://stackoverflow.com/questions/17191410/gradle-dependencymanagement”. I found that the “Unable to initialize POM pom-default.xml: Failed to validate POM for project” was because my directory structure is:
project
assembly
mbean-common
webapps/e2am
So, I have a settings.gradle file like this:
rootProject.name = ‘e2am-parent’ include “mbean-common”, “webapps/e2am”, “assembly”
And the pom-default.xml that was generated by gradle when I do “gradle clean install” by default creates an artifactId of “webapps/e2am”:
<groupId>com.e2open.platform</groupId>
<artifactId>webapps/e2am</artifactId>
<version>9.0-SNAPSHOT</version>
and the ‘/’ is apparently not allowed (because if I remove it and do mvn help:effective-pom on the file, it croaks when the ‘/’ is there and succeeds when I remove the ‘/’)
How do I tell gradle to NOT use ‘webapps/e2am’ for the artifactId, i.e. how do I override the default artifactId name? I googled for “gradle override artifactId” but I can’t seem to find the right recipe…
I’m using the java plugin and the maven plugin so gradle ‘knows’ what “clean install” should do, and at this point I’m not uploading to an archive so the solutions that I found that related to uploading to an archive seem irrelevant.
Just seems odd that in a maven pom file I can specify groupId, ArtifactID, and version, but in a build.gradle I can’t control the artifactId name, just the group and version.