server: Index | Files

package fswatch

import ""

Package fswatch watches directory with fsnotify.


Package Files


type Watcher Uses

type Watcher struct {
    // contains filtered or unexported fields

Watcher watches a directory.

func New Uses

func New(ctx context.Context, dir string) (*Watcher, error)

New creates new watcher watching directory. It will close when ctx is cancelled.

func (*Watcher) Close Uses

func (w *Watcher) Close() error

Close stops watcher.

func (*Watcher) Next Uses

func (w *Watcher) Next(ctx context.Context) (fsnotify.Event, error)

Next gets next watched event.

Package fswatch imports 2 packages (graph) and is imported by 1 packages. Updated 2020-10-27. Refresh now. Tools for package owners.