Discover Packages
github.com/SaidinWoT/gulf
task
watch
package
Version:
v0.0.0-...-4db743b
Opens a new window with list of versions in this module.
Published: Apr 25, 2016
License: Apache-2.0
Opens a new window with license information.
Imports: 6
Opens a new window with list of imports.
Imported by: 0
Opens a new window with list of known importers.
README
README
¶
gulf/task/watch
Task management system extended to react to filesystem events.
Expand ▾
Collapse ▴
Documentation
¶
Package watch implements filesystem event based execution of tasks atop gulf/task.
The Option type is a function that modifies a Watch.
Delay sets the delay used by Watch to identify unique file events.
All file events on a single file name (not inode) that take place within d time
of each other will be considered a single file event by Watch.
This is a debouncing mechanism, provided to trigger tasks only once despite
most text editor's usage of multiple file events while writing a file.
The default is 10 milliseconds
Globber sets the globbing function used by the Set to identify files to watch.
The default is glob.Glob
Matcher sets the matching function used by the Set to assert that
events on a file should trigger tasks.
The default is glob.Match
The Set type embeds a task.Set and extends it with the ability to
execute tasks based on filesystem events.
New returns a new Set, initialized to use glob.Match and glob.Glob.
SetOption modifies s with Options provided.
Start begins watching all of the directories containing files added to s.
Watch adds a set of tasks to the list that will be executed when any of the provided patterns are matched.
Source Files
¶
Click to show internal directories.
Click to hide internal directories.