4 ms·
Thanks for making me aware of this. This is linux specific but something like this seems to be available on Mac OS X (https://github.com/alandipert/fswatch http
by jhh 13y ago
Thanks for making me aware of this. This is linux specific but something like this seems to be available on Mac OS X (https://github.com/alandipert/fswatch https://github.com/alandipert/fswatch).
I don't quite understand where in your command you specify that make is executed? Could you expand on that.
- dota168 13y agowhile read; do make; done
- philsnow 13y agothat's spot on. the command "inotifywait -m -r . -e {some events}" recursively watches all inodes in the current directory (the "-r" and "." parts) for events in the {some events} list, and every time something happens (you save a file, create a new one, open a file, etc etc), inotifywait prints a line. The "-m" flag makes it print a line and keep watching. Without that, it's a one-shot (which can work like [0] but all the setting up and tearing down of inotify watches is expensive on a large project). [0] $ while inotifywait -e some,events -r . ; do make; done