Repeatedly execute a bash command and observe its output
You can have a command repeatedly executed and the output displayed. This is useful e.g. for monitoring file system changes with ls
, but has many more applications.
The update frequency is controlled by the -n
argument (default: 2s), which is locale-specific; i.e. you might need to use a comma as delimiter.
> watch -n 1.5 ls