Put [+format] at the end of the usage message.

Make `date -?' output (pretty much) the same as
the man page
PR:		5269
This commit is contained in:
Brian Somers 1997-12-11 02:38:56 +00:00
parent 3a2dc656bc
commit ad1c694bdc
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=31668
2 changed files with 8 additions and 7 deletions

View File

@ -33,7 +33,7 @@
.\" SUCH DAMAGE.
.\"
.\" @(#)date.1 8.3 (Berkeley) 4/28/95
.\" $Id: date.1,v 1.20 1997/10/03 12:49:28 danny Exp $
.\" $Id: date.1,v 1.21 1997/10/03 18:09:17 wosch Exp $
.\"
.Dd November 17, 1993
.Dt DATE 1
@ -43,14 +43,14 @@
.Nd display or set date and time
.Sh SYNOPSIS
.Nm date
.Op Fl nu
.Op Fl d Ar dst
.Op Fl r Ar seconds
.Op Fl t Ar minutes_west
.Op Fl nu
.Op Cm + Ns Ar format
.Op Fl v Ar [+|-]val[ymwdHM]
.Op Fl v Ns Ar [+|-]val Ns Op ymwdHM
.Ar ...
.Op Fl f Ar fmt Ar date | [[[[yy]mm]dd]HH]MM[\&.ss]
.Op Cm + Ns Ar format
.Sh DESCRIPTION
.Nm
displays the current date and time when invoked without arguments.

View File

@ -30,7 +30,7 @@
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
* $Id: date.c,v 1.7.2.5 1997/10/01 06:12:58 danny Exp $
* $Id: date.c,v 1.21 1997/10/03 12:49:28 danny Exp $
*/
#ifndef lint
@ -276,7 +276,8 @@ static void
usage()
{
(void)fprintf(stderr, "%s\n%s\n",
"usage: date [-nu] [-d dst] [-r seconds] [-t west] [+format]",
" [-v [+|-]val[ymwdHM]] ... [-f fmt date | [[[[yy]mm]dd]HH]MM[.ss]]");
"usage: date [-nu] [-d dst] [-r seconds] [-t west] "
"[-v[+|-]val[ymwdHM]] ... ",
" [-f fmt date | [[[[yy]mm]dd]HH]MM[.ss]] [+format]");
exit(1);
}