Hi,

I work for a company that produces hundreds of artifacts which depend on
each other. I'm trying to use `dependency:tree` to create a graph (with
graphviz) to better understand the relationships of these artifacts. The
problem I'm running into is that the graph is so large it is almost
useless. I would like to filter the results such that only dependencies
from my companies base group id are included in the graph.

Assume that all artifacts produced by our company contain the base group id
of `com.foo.bar.*`. Here is what I am trying:

    mvn dependency:tree -DexcludeScope=test -DexcludeTransitive=true
-DexcludeGroupIds=* -DincludeGroupIds=com.foo.bar.* -DappendOutput=true
-DoutputType=dot -DoutputFile=dependency-graph.gv

Using this command I would expect the results to only include explicitly
declared dependencies in pom.xml whose group id matches the `com.foo.bar.*`
group id. But instead the graph still contains other dependencies such as
`org.mockito:mockit-core:jar:1.9.5:test`. In fact, all the dependencies
included in the graph are `test` scoped.

How can I use the maven-dependency-plugin to generate a graph of a
project's first level, explicitly declared, dependencies, filtered to only
include dependencies whose group id matches some regular expression?


I asked this question on StackOverflow if you would like to answer there
instead.

http://stackoverflow.com/questions/40137300/graph-project-dependencies-including-only-company-artifacts

Reply via email to