Blog of Raivo Laanemets

Software development and personal stories.

Watch: periodically run a command

On 2014-06-29

Watch is a command line utility that executes a command periodically, showing its output. This is incredibly useful for continuously building a project during development. As I usually use make for building my projects, I can run:

watch make

The default settings (interval 2 seconds) are quite optimal for this use case.

Watch is available by default on most Linux distributions and can be easily installed on Mac.