Refactor notify dependency configuration and enhance VFS watch setup

- Updated Cargo.toml to conditionally configure the notify dependency for macOS and other platforms.
- Improved ServeSession's VFS watch logic to filter out ignored directories based on glob patterns, optimizing resource usage and watch handle count.
- Introduced PathIgnoreRule handling to streamline directory watching, enhancing overall performance and maintainability.
This commit is contained in:
Joe 2026-03-06 23:22:54 -06:00
parent 0243181731
commit 8acbfc0cf8
2 changed files with 40 additions and 9 deletions

View file

@ -21,8 +21,11 @@ log = "0.4"
notify-debouncer-full = "0.7"
serde = { version = "1.0.228", features = ["derive"] }
[dependencies.notify]
version = "8.2"
[target.'cfg(target_os = "macos")'.dependencies]
notify = { version = "8.2", features = ["macos_kqueue"] }
[target.'cfg(not(target_os = "macos"))'.dependencies]
notify = "8.2"
[dev-dependencies]
tempfile = "3.26.0"