Maven - view dependency tree

Hi

Maven 2 has a dependency plugin, with a useful goal called "tree" (mvn dependency:tree). This shows the complete tree of dependencies Maven is evaluating for inclusion. It's useful for debugging when a transitive dependency gets included and you're not sure where it's coming from.

Will there be support for this in IDEA? Currently I have to return to the command line to look into dependency problems. Ideally (hehe) I'd like to see the dependency tree and select which transitive dependencies should be excluded in the POM.


Thanks
Patrick

4 comments
Comment actions Permalink

I agree that a dependency tree GUI with navigation would be nice to have.

However, even now you can invoke "dependency:tree" goal from within IDEA.
You can create a new Maven run configuration, specify your pom and "dependency:tree" as a goal in the settings. Then you can run it and see the output in the console.
Alternatively, if you have dependency plugin listed in your pom, you can simply run the goal from the "Maven projects" pane (double click ]]>/Plugins/dependency/dependency:tree).

0
Comment actions Permalink

Hi, Patrick,

There is a request for this feature: IDEADEV-30453. It is likely to be implemented after 8.0 release.

Thanks,
Anton Makeev

0
Comment actions Permalink

I agree that a dependency tree GUI with navigation would be nice to have.

However, even now you can invoke "dependency:tree" goal from within IDEA.
You can create a new Maven run configuration, specify your pom and "dependency:tree" as a goal in the settings. Then you can run it and see the output in the console.
Alternatively, if you have dependency plugin listed in your pom, you can simply run the goal from the "Maven projects" pane (double click <project name>/Plugins/dependency/dependency:tree).


OK, I will try both of these. I'm hoping that over time, though, JetBrains will build some smart tools for managing dependencies graphically--seeing the transitive dependencies, including or excluding, version management, etc. But I can live with the text output for now.


Cheers
Patrick

0
Comment actions Permalink

Hi, Patrick,

There is a request for this feature: IDEADEV-30453. It is likely to be implemented after 8.0 release.

Thanks,
Anton Makeev


Ah, thanks for pointing that out.


Cheers
Patrick

0

Please sign in to leave a comment.