blob: aad6de1b9174fea7072f8e3721bf215eb8b9f66b (
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
32
33
|
#!/bin/sh
# This file is a script that converts the .nom files in lib/ into slightly more optimized
# precompiled versions that are only lua> ".." and =lua ".." bits which are faster to load.
FLUSH=false
while getopts ":f" opt; do
case $opt in
f)
FLUSH=true
echo "flushing..."
;;
esac
done
if [ "$FLUSH" = true ] ; then
rm core/*.lua
rm lib/*.lua
#rm tests/*.lua
fi
for file in core/*.nom; do
printf "Compiling $file ..."
./nomsu.moon -o "core/$(basename $file .nom).lua" $file
echo "done."
done
for file in lib/*.nom; do
printf "Compiling $file ..."
./nomsu.moon -o "lib/$(basename $file .nom).lua" $file
echo "done."
done
#for file in tests/*.nom; do
# printf "Compiling $file ..."
# ./nomsu.moon -c $file
# echo "done."
#done
|