diff options
author | tv <tv@xso> | 2011-08-31 23:50:23 +0200 |
---|---|---|
committer | tv <tv@xso> | 2011-08-31 23:50:23 +0200 |
commit | e69dc0b22e2335d6c8f8bf2f11a5c6c767d1715d (patch) | |
tree | ad086953938b76cb9547d8cefcae6ccbf835f5fb /retiolum/scripts/adv_graphgen/sanitize.sh | |
parent | 09d6dd479e62372badb4684c5718038f72198295 (diff) | |
parent | a001a6f2e5bf9a594e42038f5f7b49381ed8ca04 (diff) |
Merge branch 'master' of github.com:krebscode/painload
Diffstat (limited to 'retiolum/scripts/adv_graphgen/sanitize.sh')
-rwxr-xr-x | retiolum/scripts/adv_graphgen/sanitize.sh | 18 |
1 files changed, 10 insertions, 8 deletions
diff --git a/retiolum/scripts/adv_graphgen/sanitize.sh b/retiolum/scripts/adv_graphgen/sanitize.sh index 38281fba..df6216fa 100755 --- a/retiolum/scripts/adv_graphgen/sanitize.sh +++ b/retiolum/scripts/adv_graphgen/sanitize.sh @@ -1,17 +1,19 @@ +#!/bin/sh +HERE=$(dirname `readlink -f $0`) GRAPH_SETTER1=dot GRAPH_SETTER2=circo GRAPH_SETTER3='neato -Goverlap=prism ' GRAPH_SETTER4=sfdp -LOG_FILE=/var/log/everything.log +LOG_FILE=/var/log/syslog OPENER=/bin/true sudo pkill -USR2 tincd sudo sed -n '/tinc.retiolum/{s/.*tinc.retiolum\[[0-9]*\]: //gp}' $LOG_FILE |\ - ./parse.py > retiolum.dot + $HERE/parse.py > $HERE/retiolum.dot -$GRAPH_SETTER1 -Tpng -o $1retiolum_1.png retiolum.dot -$GRAPH_SETTER2 -Tpng -o $1retiolum_2.png retiolum.dot -$GRAPH_SETTER3 -Tpng -o $1retiolum_3.png retiolum.dot -$GRAPH_SETTER4 -Tpng -o $1retiolum_4.png retiolum.dot -$OPENER retiolum_1.png &>/dev/null -rm retiolum.dot +$GRAPH_SETTER1 -Tpng -o $1/retiolum_1.png $HERE/retiolum.dot +$GRAPH_SETTER2 -Tpng -o $1/retiolum_2.png $HERE/retiolum.dot +$GRAPH_SETTER3 -Tpng -o $1/retiolum_3.png $HERE/retiolum.dot +$GRAPH_SETTER4 -Tpng -o $1/retiolum_4.png $HERE/retiolum.dot +$OPENER $HERE/retiolum_1.png &>/dev/null +rm $HERE/retiolum.dot |