blob: 6b91a92f092d40ecb6701c9ce522f8b0f4798cc7 [file] [log] [blame]
#!/usr/bin/env bash
# TODO: Find a less trashy way to get the next available error code
if ! shopt -s globstar
then
echo "Error: This script depends on Bash 4." >&2
exit 1
fi
for i in 1 2
do
last=$(grep -hv "^prop" ./**/*.hs | grep -Ewo "$i[0-9]{3}" | sort -n | tail -n 1)
echo "Next ${i}xxx: $((last+1))"
done