Expand description
Notice when a file changes on disk.
A rebase, a formatter, or another editor writes the file while it is open. Without this the editor neither reloads nor warns, and the next save silently overwrites whatever the other writer did.
Structs§
- File
Watch - A live watch. Dropping it stops the watching, which is how opening another file replaces the old watch rather than accumulating them.
Functions§
- watch_
file - Report changes to
pathby callingon_changefrom the watcher’s thread.