https://github.com/olebedev/on
CLI for fsnotify
https://github.com/olebedev/on
Last synced: about 1 year ago
JSON representation
CLI for fsnotify
- Host: GitHub
- URL: https://github.com/olebedev/on
- Owner: olebedev
- License: other
- Created: 2016-04-29T10:51:43.000Z (about 10 years ago)
- Default Branch: master
- Last Pushed: 2020-01-28T04:46:24.000Z (over 6 years ago)
- Last Synced: 2025-05-08T00:45:09.407Z (about 1 year ago)
- Language: Go
- Size: 638 KB
- Stars: 9
- Watchers: 1
- Forks: 1
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# on
Command line interface for [fsnotify](https://github.com/fsnotify/fsnotify).
It watches the files and writes the event right into _stdout_. Pretty useful to complex bash pipe's manipulation.
### Usage
Install: `go get github.com/olebedev/on` or compiled binaries at [releases](https://github.com/olebedev/on/releases) page.
```
$ on --help
NAME:
on - cli for fsnotify
USAGE:
on [options] [path]
Path could be mix of folders and filepaths, default is '.'.
Regular usecase is watch the file's changes and execute some
bash script or command line tool. It could be done in this way:
on | xargs -n1 -I{}
VERSION:
0.1.0
AUTHOR(S):
olebedev
COMMANDS:
GLOBAL OPTIONS:
--template, -t "{{.Name}}" output template to render received event, see: https://godoc.org/gopkg.in/fsnotify.v1#Event
--mask, -m "15" event's bitwise mask, see: https://godoc.org/gopkg.in/fsnotify.v1#Op
--help, -h show help
--version, -v print the version
```
### License
MIT