3

Is there an easy way to make maven list the parent POMs a POM inherits directly and indirectly?

I'm looking for something similar to

mvn dependency:tree

only "upstream" (i.e. for parent POMs inherited), not "downstream" (i.e. for dependencies on other libraries)...

Christian
  • 6,070
  • 11
  • 53
  • 103

2 Answers2

1

I wanted to print the version of our corporate parent POMs. I used the GMaven plugin for this, as described in this stackoverflow answer. You could modify that code bit to print each parent POM.

Community
  • 1
  • 1
user944849
  • 14,524
  • 2
  • 61
  • 83
0

I don't know a Maven command to do this. If you use Eclipse and the m2e plugin, then you can press F3 inside of the <parent> element to visit the parent POM. Then rinse and repeat.

Aaron Digulla
  • 321,842
  • 108
  • 597
  • 820