From 64b8c083f9685b15b9c9eb9af787f679daad012c Mon Sep 17 00:00:00 2001 From: Zach van Rijn Date: Sat, 30 Apr 2022 01:00:37 -0500 Subject: scripts/*: add dependency resolver. --- scripts/dotty | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100755 scripts/dotty (limited to 'scripts/dotty') diff --git a/scripts/dotty b/scripts/dotty new file mode 100755 index 000000000..45bbd8d1d --- /dev/null +++ b/scripts/dotty @@ -0,0 +1,19 @@ +#!/bin/sh -e + +## +# CLOSE THIS FILE! DO NOT LOOK BELOW! +# + + +# ./scripts/deplist system | ./scripts/dotty + +printf "digraph G {\n"; +while read k; do + a=$(printf "%s " "${k}" | cut -d' ' -f1); + printf " \"%s\n" "${a}"; + for b in $(seq 2 $(_() { printf "%s" "${#}"; }; _ ${k})); do + printf " \"%s\" -> \"" "${a}"; + printf "%s " "${k}" | cut -d' ' -f${b}; + done +done | sed -e 's/$/";/g' +printf "}\n"; -- cgit v1.2.3-60-g2f50