1WATCH(1)                      Linux User's Manual                     WATCH(1)
2
3
4

NAME

6       watch - execute a program periodically, showing output fullscreen
7

SYNOPSIS

9       watch  [-dhvt]  [-n  <seconds>]  [--differences[=cumulative]]  [--help]
10       [--interval=<seconds>] [--no-title] [--version] <command>
11

DESCRIPTION

13       watch runs command repeatedly, displaying its output (the first screen‐
14       full).   This  allows you to watch the program output change over time.
15       By default, the program is run every 2 seconds; use -n or --interval to
16       specify a different interval.
17
18       The  -d  or  --differences  flag will highlight the differences between
19       successive  updates.   The  --cumulative  option   makes   highlighting
20       "sticky",  presenting a running display of all positions that have ever
21       changed.  The -t or --no-title option turns off the header showing  the
22       interval,  command, and current time at the top of the display, as well
23       as the following blank line.
24
25       watch will run until interrupted.
26

NOTE

28       Note that command is given to "sh -c" which means that you may need  to
29       use extra quoting to get the desired effect.
30
31       Note  that  POSIX  option  processing  is used (i.e., option processing
32       stops at the first non-option argument).  This means that  flags  after
33       command don't get interpreted by watch itself.
34

EXAMPLES

36       To watch for mail, you might do
37
38              watch -n 60 from
39
40       To watch the contents of a directory change, you could use
41
42              watch -d ls -l
43
44       If you're only interested in files owned by user joe, you might use
45
46              watch -d 'ls -l | fgrep joe'
47
48       To see the effects of quoting, try these out
49
50              watch echo $$
51
52              watch echo '$$'
53
54              watch echo "'"'$$'"'"
55
56       You can watch for your administrator to install the latest kernel with
57
58              watch uname -r
59
60       (Just kidding.)
61

BUGS

63       Upon  terminal resize, the screen will not be correctly repainted until
64       the next scheduled update.  All --differences highlighting is  lost  on
65       that update as well.
66
67       Non-printing characters are stripped from program output.  Use "cat -v"
68       as part of the command pipeline if you want to see them.
69

AUTHORS

71       The original watch was written  by  Tony  Rems  <rembo@unisoft.com>  in
72       1991,  with  mods  and corrections by Francois Pinard.  It was reworked
73       and new features added by Mike Coleman <mkc@acm.org> in 1999.
74
75
76
77                                  1999 Apr 3                          WATCH(1)
Impressum