diff --git a/src/main.rs b/src/main.rs index 4352b07..7ab5e9c 100644 --- a/src/main.rs +++ b/src/main.rs @@ -83,7 +83,7 @@ async fn main() -> anyhow::Result<()> { let meta = args.meta.clone(); tokio::spawn(async move { let inotify = Inotify::init()?; - inotify.watches().add(meta, WatchMask::MODIFY)?; + inotify.watches().add(meta, WatchMask::CLOSE_WRITE | WatchMask::MOVED_TO)?; let mut buf = [0; 1024]; let mut stream = inotify.into_event_stream(&mut buf)?;