Question

When I look at my effective pom in Eclipse, I can see a load of dependencies and a label stating that this is our corporate super pom which must form part of every project.

I can't actually work out where the super pom comes into play in the config. I have looked at my settings.xml in maven, and it has lists to remote repositories, and internal repositories - but can't seem to see a link to the super pom anywhere.

It is a muliple module maven project built from an internal archetype, and the parent module has a parent artefact defined...but when I browse the parent artefact, I still cant see how the super pom comes into play.

Any advice appreciated.

Regards

i

Was it helpful?

Solution

The super pom is defined by the <parent> tag:

<parent>
  <groupId>com.mycompany</groupId>
  <artifactId>mvn</artifactId>
  <version>1.0.0-SNAPSHOT</version>
</parent>

OTHER TIPS

All pom implicitly inherit from super pom which is present in the maven distribution. This pom contains defaults for all maven projects which can be overriden in your maven project. But most of these defaults are not overridden as they typically form the convention part of maven as it is a build tool geared more towards convention. For e.g., the default build directory is target and hence this configuration is present in super pom as

........
<directory>${project.basedir}/target</directory>
.........

For more information and actual location of this pom please refer here and here

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top