5

I wonder if it is possible to get information about all first level dependencies of my maven project. I need the following information: name, vendor, version, license type, reference URL, description. All this information is stored in pom.xml of each package. The problem is that we have hierarchy of about 20 projects that have several hundreds dependencies that are constantly being changed.

I know about maven dependency plugin. I ran mvn dependency:list and extracted list of packages using combination of greps and seds. But I need license information and URL. I can implement my own parser that parses pom.xml for interesting packages and extracts this information but it seems that something ready to use should exist.

AlexR
  • 114,158
  • 16
  • 130
  • 208

2 Answers2

2

The maven dependecy report may be usefull for you: maven-project-info-reports-plugin

Danubian Sailor
  • 1
  • 38
  • 145
  • 223
  • Thank you, it works. But I have a large hierarchy of projects and this plugin returns dependencies per project and does not propagate then up, i.e. upper level project does not have dependencies. I want to get report of all dependencies together. Is there a way to do this? – AlexR Nov 14 '11 at 16:22
1

The best thing is to create a site with the support of the maven-project-info-report plugin which will create the needed information. See here as an example. The only question is which version of maven are you using? Furthermore i would suggest to take a look at the maven-license-plugin If you need to limit the licenses in any way you can take a look at the maven-license-verifier plugin.

khmarbaise
  • 92,914
  • 28
  • 189
  • 235
  • Thank you, it works. But I have a large hierarchy of projects and this plugin returns dependencies per project and does not propagate then up, i.e. upper level project does not have dependencies. I want to get report of all dependencies together. Is there a way to do this? – AlexR Nov 14 '11 at 16:27
  • 1
    May be you can setup a aggregation project (pom.xml) with modules entries of your project and try to run the report on this project...directly there is no way... – khmarbaise Nov 14 '11 at 17:22