MCPcopy Index your code
hub / github.com/coder/coder / fsnotifyWatcher

Struct fsnotifyWatcher

agent/agentcontainers/watcher/watcher.go:38–46  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

36}
37
38type fsnotifyWatcher struct {
39 *fsnotify.Watcher
40
41 mu sync.Mutex // Protects following.
42 watchedFiles map[string]bool // Files being watched (absolute path -> bool).
43 watchedDirs map[string]int // Refcount of directories being watched (absolute path -> count).
44 closed bool // Protects closing of done.
45 done chan struct{}
46}
47
48// NewFSNotify creates a new file system watcher that watches parent directories
49// instead of individual files for more reliable event detection.

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected