github.com/mit-dci/lit@v0.0.0-20221102210550-8c3d3b49f2ce/scripts/callgraphs.sh (about) 1 #!/bin/bash 2 3 pkgs='qln lnutil lndc litrpc powless uspv wallit watchtower dlc elkrem portxo coinparam sig64 btcutil wire' 4 5 echo "Generating call graphs for packages: $pkgs" 6 7 outdir=build/graphs 8 mkdir -p $outdir 9 10 for p in $pkgs; do 11 graphpath=$outdir/callgraph-$p.dot 12 pngpath=$outdir/callgraph-$p.png 13 echo 'graphing:' $p 14 go-callvis \ 15 -group pkg,type \ 16 -nostd \ 17 -focus $p \ 18 -minlen 12 \ 19 . > $graphpath 20 echo 'rendering:' $p 21 dot -Tpng $graphpath -o $pngpath 22 done