#! /bin/bash # incmake 0.1 # Copyright (C) 2006 Ross Burton # Licensed under the GPL, version 2 (or above) # Do an initial build make -s # Now watch for other changes, and rebuild echo $(date +%X) "Watching..." while { inotifywait -e modify -e create -qq *; }; do echo $(date +%X) Rebuilding... make -s if [ $? -eq 0 ] ; then echo $(date +%X) Done. else echo -e \\a fi done