-
Notifications
You must be signed in to change notification settings - Fork 3
/
makeftml
executable file
·36 lines (30 loc) · 1.89 KB
/
makeftml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
#!/bin/bash
# This script rebuilds the algorithmically-generated ftml files.
set -e
if [ ! -f wscript ]
then
echo "Must be in the root of the project"
exit 2
fi
# configure tests
tests="AllChars Diac Extra Matras Nuktas"
urls='url(../references/ThiruValluvar-Regular.ttf)=refR url(../references/ThiruValluvar-Bold.ttf)=refB url(../references/ThiruValluvar-Italic.ttf)=refI url(../references/ThiruValluvar-BoldItalic.ttf)=refBI url(../results/ThiruValluvar-Regular.ttf)=grR url(../results/tests/ftml/fonts/ThiruValluvar-Regular_ot_tml2.ttf)=R url(../results/tests/ftml/fonts/ThiruValluvar-Bold_ot_tml2.ttf)=B url(../results/tests/ftml/fonts/ThiruValluvar-Italic_ot_tml2.ttf)=I url(../results/tests/ftml/fonts/ThiruValluvar-BoldItalic_ot_tml2.ttf)=BI url(../references/NotoSerifTamil-Regular.ttf)=notoSerif url(../references/NotoSerifTamilSlanted-Regular.ttf)=notoSlanted url(../references/NotoSansTamil-Regular.ttf)=notoSans url(../references/NotoSansTamilUI-Regular.ttf)=notoSansUI url(../references/TiroTamil-Regular.ttf)=tiroR url(../references/TiroTamil-Italic.ttf)=tiroI url(../references/BalooThambi2-Regular.ttf)=baloo url(../results/Auvaiyar-Regular.ttf)=aR url(../results/Auvaiyar-Bold.ttf)=aB url(../results/Auvaiyar-Italic.ttf)=aI url(../results/Auvaiyar-BoldItalic.ttf)=aBI url(../results/Vaigai-Regular.ttf)=vR url(../results/Vaigai-Bold.ttf)=vB url(../results/Vaigai-Italic.ttf)=vI url(../results/Vaigai-BoldItalic.ttf)=vBI'
langs='ctt,iru,xub,xuj'
ufo='source/ThiruValluvar-Regular.ufo'
# list all the fonts to test
fonts=''
for url in $urls
do
fonts="$fonts -s '$url'"
done
echo "Rebuilding ftml files..."
for test in $tests
do
base=${test,,}
title="\"${test} auto\""
ftml=tests/${base}.ftml
log=tests/logs/${base}.log
eval tools/psfgenftml.py -q -t "$title" --langs $langs --scale 200 -i source/glyph_data-ThiruValluvar.csv --xsl ../tools/ftml.xsl "$fonts" -l $log $ufo $ftml &
done
wait
echo "done."