blob: 864201393807c27e6b5941a59a4a11fd0090517a (
plain)
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
|
#!/usr/bin/env bash
# Quick Teal build script while we don't have Cyan integration yet
cd $(dirname $0)/src
i=0
for tealname in $(find . -name "*.tl" -not -name "*.d.tl")
do
luaname=$(echo $tealname | sed 's/.tl$/.lua/g')
if [ $tealname -nt $luaname ] || [ "$1" = "--all" ]
then
tl gen --check -I ../types $tealname -o $luaname
i=$[i+1]
fi
done
# Final message:
if [ "$1" = "--all" ]
then
what="rebuilt"
else
what="needed rebuilding"
fi
if [ "$i" = 1 ]
then
echo "$i file $what."
else
echo "$i files $what."
fi
|