Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Watcher ¶
func New ¶
New creates a watcher, watching all files and directories inside dir (recursively) If matchFiles is not nil, only the files matching matchFiles are respected. If ignore is not nil, files and directories matching ignore are ignored. An error is returned if the watcher could not be properly initialized.
func (*Watcher) Run ¶
Run runs the watching loop, reporting any errors to the errors channel, file modification and creation to the filechanged channel and file deletion and file renaming to the dirchanged channel for removal and renamed files, an empty filename is added to filechanged, since the command could not do anything meaningful with the missing file.