#!/bin/sh which inotifywait 2> /dev/null 1> /dev/null || { echo 'Could not found inotifywait'; exit 1; } files=$(find . -name '*.template.*') ./generate while true do inotifywait -q -e modify $files ./generate done