tldr/pages/common/watch.md

17 lines
360 B
Markdown
Raw Normal View History

2016-01-22 00:13:27 +00:00
# watch
> Execute a program periodically, showing output fullscreen.
> More information: <https://manned.org/watch>.
2016-01-22 00:13:27 +00:00
- Repeatedly run a command and show the result:
`watch {{command}}`
- Re-run a command every 60 seconds:
`watch -n {{60}} {{command}}`
- Monitor the contents of a directory, highlighting differences as they appear:
2016-01-22 00:13:27 +00:00
`watch -d {{ls -l}}`