Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Build a Scala package dependency graph

My scala (Activator + Play) project starts getting huge. I want to split it into multiple small packages. However, as a starting point I need to know which file/package depends on which file/package!

How can I obtain a tree or a graph of dependencies among my files?

I tried sbt-dependendy-graph but it gives external dependencies...

Any clue?

like image 236
Nicolas Cailloux Avatar asked Oct 29 '22 16:10

Nicolas Cailloux


1 Answers

The closest thing I know is acyclic, which lets you enforce that the package dependency graph is acyclic. There's already an issue asking for a way of visualizing the dependency graph. Looking at the code, it should be easy to build something like what you want, check DependencyExtraction.scala and GraphAnalysis.scala

like image 137
Eduardo Pareja Tobes Avatar answered Nov 12 '22 21:11

Eduardo Pareja Tobes