Method: FileWatch::Watch#watch
- Defined in:
- lib/filewatch/watch.rb
#watch(path) ⇒ Object
91 92 93 94 95 96 97 98 99 100 101 102 103 |
# File 'lib/filewatch/watch.rb', line 91 def watch(path) synchronized do if !@watching.member?(path) @watching << path _discover_file(path) do |filepath, stat| WatchedFile.new_initial( filepath, inode(filepath, stat), stat ).init_vars(@delimiter, @ignore_older, @close_older) end end end return true end |