]> granicus.if.org Git - procps-ng/commitdiff
watch: inform about optional argument for -d switch
authorSami Kerola <kerolasa@iki.fi>
Sat, 11 Feb 2012 20:00:05 +0000 (21:00 +0100)
committerSami Kerola <kerolasa@iki.fi>
Sat, 11 Feb 2012 20:43:28 +0000 (21:43 +0100)
The -d, --differences switch(s) can use optional argument that was
not documented earlier.

Reported-By: Marian Sigler <m@qjym.de>
Bug-Debian: http://bugs.debian.org/597021
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
watch.1
watch.c

diff --git a/watch.1 b/watch.1
index 1e82340387535f5c284b837f367b3f59721ff30b..6ed933d256f6645650cdeb6e0451e5a060f98aa4 100644 (file)
--- a/watch.1
+++ b/watch.1
@@ -15,8 +15,10 @@ program is run every 2 seconds.
 will run until interrupted.
 .SH OPTIONS
 .TP
-\fB\-d\fR, \fB\-\-differences\fR
-Highlight the differences between successive updates.
+\fB\-d\fR, \fB\-\-differences\fR [\fIpermanent\fR]
+Highlight the differences between successive updates.  Option will read
+optional argument that changes highlight to be permanent, allowing to see what
+has changed at least once since first iteration.
 .TP
 \fB\-n\fR, \fB\-\-interval\fR \fIseconds\fR
 Specify update interval.  The command will not allow quicker than 0.1 second
diff --git a/watch.c b/watch.c
index 2408e176cea9b3aa6026fc904b0d7cb21eda553e..dc1198681ae42a431104145a90d45d99c0332e98 100644 (file)
--- a/watch.c
+++ b/watch.c
@@ -67,7 +67,8 @@ static void __attribute__ ((__noreturn__))
        fputs(USAGE_OPTIONS, out);
        fputs(_("  -b, --beep             beep if command has a non-zero exit\n"
                "  -c, --color            interpret ANSI color sequences\n"
-               "  -d, --differences      highlight changes between updates\n"
+               "  -d, --differences[=<permanent>]\n"
+                "                         highlight changes between updates\n"
                "  -e, --errexit          exit if command has a non-zero exit\n"
                "  -n, --interval <secs>  seconds to wait between updates\n"
                "  -p, --precise          attempt run command in precise intervals\n"