Over a million developers have joined DZone.
{{announcement.body}}
{{announcement.title}}

Visualize Maven Project Dependencies with dependency:tree and Dot Diagram Output

DZone's Guide to

Visualize Maven Project Dependencies with dependency:tree and Dot Diagram Output

· Java Zone
Free Resource

Get the Edge with a Professional Java IDE. 30-day free trial.

The dependency:tree goal of the Maven plugin dependency supports various graphical outputs from the version 2.4 up. This is how you would create a diagram showing all dependencies in the com.example group in the dot format:

mvn dependency:tree -Dincludes=com.example-DappendOutput=true -DoutputType=dot -DappendOutput=true -DoutputFile=/path/to/output.dot

To actually produce an image from .dot you can use one of .dot renderers, f.ex. this online dot renderer (paste into the right text box, press enter).

You could also generate the output f.ex. in the graphml format & visualize it in Eclipse.

 

From http://theholyjava.wordpress.com/2012/01/13/visualize-maven-project-dependencies-with-dependencytree-and-dot-diagram-output/

Get the Java IDE that understands code & makes developing enjoyable. Level up your code with IntelliJ IDEA. Download the free trial.

Topics:

Opinions expressed by DZone contributors are their own.

{{ parent.title || parent.header.title}}

{{ parent.tldr }}

{{ parent.urlSource.name }}