File renames, or moving files into or out of the directory, weren't being detected.
This commit is contained in:
parent
3538e5ba0d
commit
74ca3426ff
1 changed files with 2 additions and 1 deletions
3
vigil
3
vigil
|
|
@ -850,7 +850,8 @@ def is_path_excluded(path):
|
|||
def make_watch_manager(root_path, callback):
|
||||
watch_manager = pyinotify.WatchManager()
|
||||
event_mask = (pyinotify.IN_CREATE | pyinotify.IN_DELETE |
|
||||
pyinotify.IN_CLOSE_WRITE | pyinotify.IN_ATTRIB)
|
||||
pyinotify.IN_CLOSE_WRITE | pyinotify.IN_ATTRIB |
|
||||
pyinotify.IN_MOVED_FROM | pyinotify.IN_MOVED_TO)
|
||||
watch_manager.add_watch(root_path, event_mask, rec=True, auto_add=True,
|
||||
proc_fun=callback, exclude_filter=lambda path:
|
||||
is_path_excluded(path))
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue