Reputation: 1629
There are multiple modules in one web project and the project uses maven to manage the jars. I am curious that how to find which dependency in pom.xml the jar belongs to ? for example. in ROOT.war/WEB-INF/lib/xxx.jar
I want to find the dependency A in pom.xml which includes the jar. dependency A -> denpendency B -> denpendency xxx (xxx.jar)
Upvotes: 0
Views: 704
Reputation: 6519
mvn dependency:tree
will print out a tree of how your dependencies are being resolved.
You can search that output for the jar you are interested in.
There's probably other ways to work it out, but I tend to just pick a small set of generally useful commands and rely on them for most tasks
Upvotes: 1