require 'INotify' a = INotify.new() a.watch_dir("/tmp/testinotify/", INotify::IN_ALL_EVENTS) do |event| puts event.mask_name+" "+event.filename end