loom
1#!/bin/bash
2
3# Формирование изображений диаграм АСД для основных операций SBL
4
5dir=doc/tree
6png=fuze
7
8if [ -d $dir/$png ]
9then
10echo $dir/$png exists, cleaning...
11#rm -rf $dir/$png/*.png
12else
13mkdir $dir
14mkdir $dir/$png
15fi
16
17echo Starting to create diagrams...
18
19for file in data/grammar/*.fuze
20do
21echo ${file}
22fbname=$(basename "$file" | cut -d. -f1)
23bin/simodo-grammatize -S ${file} -s test/tmp/${fbname}.dot
24if [ -e test/tmp/${fbname}.dot ]
25then
26dot -Tpng test/tmp/${fbname}.dot -o${dir}/$png/${fbname}.png
27fi
28done
29
30rm -rf test/tmp/*.dot
31