pub fn stale_paths(store: &Store) -> Result<Vec<String>>Expand description
Compute repository-relative paths whose indexed snapshot no longer matches the working tree: modified, deleted, AND added files, from ONE authoritative scan diffed against the indexed inventory — a newly created relevant file must make the model non-current, and indexed files are never re-read when the scan already hashed them (one read+hash per file per freshness check, not two). Same scan the indexer uses, so both sides share one notion of “repository file” (git-ignored and configured-ignored paths excluded).
Scaling note: the authoritative scan still reads every candidate file (correctness first — no mtime cache exists yet, so content hashing is the only proof of sameness). The scan walk itself is the periodic reconciliation; a watcher dirty-set + metadata fast path stays deferred until a daemon owns it.