From c2b788ad50ae39003ded89db5284240ec542664c Mon Sep 17 00:00:00 2001 From: Albert S Date: Sun, 30 Jul 2017 10:45:10 +0200 Subject: [PATCH] updated README.md --- README.md | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index baf3f1d..78967f6 100644 --- a/README.md +++ b/README.md @@ -1,9 +1,10 @@ What is adhocify? ================= + adhocify uses inotify to watch for file system events. Once an event occurs it can execute a script. The path of the file and the event -will be passed to that script. - +will be passed to that script. + Requirements ============ adhocify only runs on Linux. You need a kernel and libc with inotify @@ -45,4 +46,8 @@ adhocify -w /tmp -i *.txt /home/user/myscript.sh * Watches for IN\_CLOSE\_WRITE events in /tmp/ but will not pass *.txt files to the script - +find . -type d | adhocify -s /home/user/myscript.sh + + * Starts monitoring every subdirectory of the current path for IN\_CLOSE\_WRITE events. However, inotify has + limits, thus it may not always work, e. g. when inotify descriptors are being used by other programs or the tree is too large. Therefore adhocify will exit + if it cannot setup a watch for all supplied directories. See inotify(7), /proc/sys/fs/inotify/.