How to install and use Watchman

Watchman is a server-client tool to watch files and directories for changes. It uses the inotify mechanism of the Linux kernel to achieve this.

There seems to be no package or PPA of Watchman for Ubuntu. But, installing it from source is easy:

$ git clone
$ cd watchman
$ ./
$ ./configure
$ make
$ sudo make install

To ask Watchman to watch a directory for changes:

$ watchman watch /path/to/dir

By default, Watchman writes the changes it notices to its log file. The log file can be found in /tmp/.watchman.yourusername.log.

If you want to uninstall Watchman, go to the source directory and try:

$ sudo make uninstall
( cd '//usr/local/bin' && rm -f watchman )
( cd '//usr/local/share/doc/watchman-3.0.0' && rm -f README.markdown )

Tried with: Watchman 3.0.0 and Ubuntu 14.04

9 thoughts on “How to install and use Watchman

  1. Works great.

    I just had a little problem though, I needed to install python-dev package (“sudo apt-get install python-dev”). Otherwise it would give me this error when trying to run make: “fatal error: Python.h: No such file or directory compilation terminated.”


  2. If anyone happens to hit this up and get a problem indicating something like:

    ryan:~/workspace/watchman$ ./
    ./ 9: ./ aclocal: not found
    ./ 10: ./ autoheader: not found
    ./ 11: ./ automake: not found
    ./ 12: ./ autoconf: not found

    You’ll need to install automake && autoconf.

    sudo apt-get install automake autoconf

    Then proceed with the steps for ./, etc.

    Liked by 1 person

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.