前段时间在网上发现了一个好东西,是Maven2的一个reporting插件,可以让你看到项目的Dependencies之间的关系,还有树等,实在太强了,下面我将会介绍一下使用方法,及贴上一些生成的图!
具体介绍请参阅:
http://maven.apache.org/plugins/maven-project-info-reports-plugin/index.html
使用方法介绍:
在你的项目的pom里,<project>与</project>标签之间,插入下面一段xml代码
<reporting>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>
maven-project-info-reports-plugin
</artifactId>
</plugin>
</plugins>
</reporting>
如果是有多个Modules的项目,只在最顶层的pom里加即可看到整个project的Dependencies关系,然后用命令行进入加了这个插件的project的根目录
运行 mvn project-info-reports:dependencies 只生成dependencies关联信息
或
运行 mvn site 生成项目所有相关信息,下面为这些信息的列表
About | There is currently no description associated with this project. |
Continuous Integration | This is a link to the definitions of all continuous integration processes that builds and tests code on a frequent, regular basis. |
Dependencies | This document lists the project's dependencies and provides information on each dependency. |
Issue Tracking | This is a link to the issue management system for this project. Issues (bugs, features, change requests) can be created and queried using this link. |
Mailing Lists | This document provides subscription and archive information for this project's mailing lists. |
Project License | This is a link to the definitions of project licenses. |
Project Plugins | This document lists the build plugins and the report plugins used by this project. |
Project Summary | This document lists other related information of this project |
Project Team | This document provides information on the members of this project. These are the individuals who have contributed to the project in one form or another. |
Source Repository | This is a link to the online source repository that can be viewed via a web browser.
|
下面贴几个图出来给大家瞧瞧