Improved dirstamp: dirstamp.lst: [ ! -e $@ -o -n "$(find dir/ -newer $@ -print -quit)" ] && touch $@ || :;