watcher

package
v0.3.857 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 25, 2025 License: MIT Imports: 9 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func WalkFiles

func WalkFiles(ctx context.Context, path string, watchPattern *regexp.Regexp, out chan fsnotify.Event) (err error)

WalkFiles walks the file tree rooted at path, sending a Create event for each file it encounters.

Types

type RecursiveWatcher

type RecursiveWatcher struct {
	WatchPattern *regexp.Regexp
	Events       chan fsnotify.Event
	Errors       chan error
	// contains filtered or unexported fields
}

func NewRecursiveWatcher added in v0.3.819

func NewRecursiveWatcher(ctx context.Context, w *fsnotify.Watcher, watchPattern *regexp.Regexp, events chan fsnotify.Event, errors chan error) *RecursiveWatcher

func Recursive

func Recursive(
	ctx context.Context,
	path string,
	watchPattern *regexp.Regexp,
	out chan fsnotify.Event,
	errors chan error,
) (w *RecursiveWatcher, err error)

func (*RecursiveWatcher) Add

func (w *RecursiveWatcher) Add(dir string) error

func (*RecursiveWatcher) Close

func (w *RecursiveWatcher) Close() error

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL