2 ms·
[inotify-tools](https://github.com/rvoicilas/inotify-tools/wiki https://github.com/rvoicilas/inotify-tools/wiki) is the stuff you want. There's a nice utility c
by arjie 13y ago
[inotify-tools](https://github.com/rvoicilas/inotify-tools/wiki https://github.com/rvoicilas/inotify-tools/wiki) is the stuff you want. There's a nice utility called inotifywait in there which will block until there's a change in a file or directory (it does recursive as well).
You can get results from as simple as this bash one-liner:
while(true); do inotifywait --exclude '.*.swp' -e close_write dir; make; done
I wrote that off the top of my head so it may not work straight off, but you get the idea.