blob: 32619f3d797240f3f18e20f56b263250bc636e3f (
plain) (
blame)
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
|
#!/bin/sh
if [ -z "$1" ]; then
echo "Usage: $0 <reducer>"
exit 1
fi
echo "# useful for running all tests of the standard library" >All.bruijn
echo >>All.bruijn
FILES="$(find * -type f -name "*.bruijn" ! -name "All.bruijn")"
for f in $FILES; do
echo ":import std/${f%*.bruijn} ." >>All.bruijn
done
# for ci, just run `bruijn All.bruijn`
echo >>All.bruijn
echo "main [[0]]" >>All.bruijn
if cat /dev/null | bruijn -v All.bruijn -r "$1" | tee /dev/fd/2 | grep -q "ERROR"; then
exit 1
fi
hyperfine --warmup 5 --runs 20 "cat /dev/null | bruijn -r $1 All.bruijn"
|