https://pantsbuild.org/ logo
#general
Title
# general
s

shy-advantage-49800

12/28/2022, 11:03 AM
Hi there 👋 Does anyone have an script to visualize a dependency graph with pants? Mentioning this because I've just found this webpage, and on the Dependency Graph Visualization section says that we can do with other visualization tools... So just wondering how people are doing it, and using it to do that.
b

bitter-ability-32190

12/28/2022, 12:29 PM
The command you seek is
./pants peek ::
that'll output json you need to pipe into dot or make a nice d3 graph
s

shy-advantage-49800

12/28/2022, 1:25 PM
I was actually seeking the last part "you need to pipe into dot or make a nice d3 graph", or is it super simple?
b

bitter-ability-32190

12/28/2022, 1:55 PM
At one point I had a script to produce a weighted d3 graph, but it got lost to time
Also @happy-kitchen-89482's company has a website you can use on public repos. https://graphmyrepo.com/
b

busy-vase-39202

12/28/2022, 2:22 PM
Yup, the latter makes nice interactive dep graphs. Having pants in the repo isn't even required.
b

bitter-ability-32190

12/28/2022, 2:44 PM
I think that uses d3 weighted graphs as well. I wouldn't mind some of that code making it's way to a plugin 👀
h

happy-kitchen-89482

12/28/2022, 4:55 PM
We have been considering what to do with the graphmyrepo code, whether to make it work on private repos as a premium Toolchain feature, or something
4 Views