noah.is/watch.sh
2018-07-03 19:41:33 -07:00

15 lines
314 B
Bash
Executable File

#!/bin/bash
function die() {
echo >&2 $1
exit 1
}
# Before we crash and burn, make sure necessary programs are installed!
command -v inotifywait || die "I need the inotifywait command (apt install inotify-tools)"
make
while inotifywait -r -e modify,move,create,delete static templates; do
make
done