Inotify

Inotify is the kernel module that replaces.... @todo

it allows you to attached watches to particular file system structures and have events called.

notes & references

https://github.com/rvoicilas/inotify-tools/wiki/

http://www.ibm.com/developerworks/linux/library/l-ubuntu-inotify/index.html http://northernmost.org/blog/tooltip-inotify-tools/ http://linux.die.net/man/1/inotifywait

#!/bin/sh while inotifywait -e modify /var/log/messages; do        if tail -n1 /var/log/messages | grep httpd; then kdialog --msgbox "Apache needs love!" fi    done while true; do echo "Waiting for file changes" inotifywait -rq --format '%T %w %f' -e close_write "path/to/files" echo "Files were changed" done