Skip to content

larryfox/watch

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

17 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

watch

Watch a directory, file, or files for changes and run a command.

Usage

$ watch [-n] <path> [<cmd>...]

When multiple changes happen quickly changes are buffered and grouped into one event.

  • cmd is ran once per event
  • -n splits the filenames of an event onto new lines. By default they are seperated by a colon.

Examples

$ watch Source/ make
$ watch js/ npm run build
$ watch -n js/ | xargs -I '%' cat %

Installing

$ make install

Compiling with Swift 3.1

Why

Most watch utilites either poll on an interval or require complicated configuration. This uses FSEvents and has a simple api.

About

Watch a directory, file, or files for changes and run a command

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published