]> git.ipfire.org Git - thirdparty/coreutils.git/commitdiff
doc: date: clarify which options are mutually exclusive
authorPádraig Brady <P@draigBrady.com>
Sun, 24 Jul 2022 19:49:29 +0000 (20:49 +0100)
committerPádraig Brady <P@draigBrady.com>
Sun, 24 Jul 2022 20:09:24 +0000 (21:09 +0100)
* src/date.c (usage): Specify that --date, --file, --reference,
and --resolution are mutually exclusive.  This is also useful
documentation to group similar options.
* doc/coreutils.texi (Options for date): Likewise.
Addresses https://bugs.gnu.org/55401

doc/coreutils.texi
src/date.c

index e0c87d1ad70a304bef94b6c2e982095f71d5ca93..53257f7d9f69848e331b57b5c074270f92bc8403 100644 (file)
@@ -16426,6 +16426,10 @@ relative to Universal Time rather than to the local time zone.
 The program accepts the following options.  Also see @ref{Common options}.
 Except for @option{-u}, these options are all GNU extensions to POSIX.
 
+All options that specify the date to display are mutually exclusive.
+I.e.: @option{--date}, @option{--file}, @option{--reference},
+@option{--resolution}.
+
 @table @samp
 
 @item -d @var{datestr}
index 7f2ac801d7c7a483136f1d0855fc3811956ca6c5..ff5c548c0bb12ea214afa039b9b894142aa9bfbf 100644 (file)
@@ -183,6 +183,11 @@ With -s, or with [MMDDhhmm[[CC]YY][.ss]], set the date and time.\n\
       fputs (VERSION_OPTION_DESCRIPTION, stdout);
       fputs (_("\
 \n\
+All options that specify the date to display are mutually exclusive.\n\
+I.e.: --date, --file, --reference, --resolution.\n\
+"), stdout);
+      fputs (_("\
+\n\
 FORMAT controls the output.  Interpreted sequences are:\n\
 \n\
   %%   a literal %\n\