MCPcopy Create free account
hub / github.com/atomicdotdev/atomic / create_watcher

Function create_watcher

atomic-agent/src/watcher/mod.rs:393–395  ·  view source on GitHub ↗

Create a [`FileWatcher`] using the best available backend. Attempts to connect to Watchman first. If Watchman is not running or the connection fails, falls back to the snapshot-based watcher. # Arguments `config` — Watcher configuration (repo root, ignore patterns) # Returns A boxed `FileWatcher` implementation. The caller does not need to know which backend was selected. # Implementation St

(config: WatcherConfig)

Source from the content-addressed store, hash-verified

391/// watcher is always the snapshot fallback — see
392/// [`create_watcher_with_tier`] for the explicit tier selection.
393pub async fn create_watcher(config: WatcherConfig) -> AgentResult<Box<dyn FileWatcher>> {
394 Ok(create_watcher_with_tier(config).await?.0)
395}
396
397// Tests
398

Callers 4

newMethod · 0.85

Calls 1

create_watcher_with_tierFunction · 0.85