Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 25 Oct 1999 05:00:01 -0700 (PDT)
From:      Sheldon Hearn <sheldonh@uunet.co.za>
To:        freebsd-bugs@FreeBSD.org
Subject:   Re: bin/14472: date for Y#K 
Message-ID:  <199910251200.FAA94092@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help
The following reply was made to PR bin/14472; it has been noted by GNATS.

From: Sheldon Hearn <sheldonh@uunet.co.za>
To: j_guojun@lbl.gov
Cc: FreeBSD-gnats-submit@FreeBSD.ORG
Subject: Re: bin/14472: date for Y#K 
Date: Mon, 25 Oct 1999 13:50:12 +0200

 On Mon, 25 Oct 1999 13:28:07 +0200, Sheldon Hearn wrote:
 
 > The following patch should give you what you want.  Note that you can
 > only specify 4-digit years within the range 1902-2037.
 
 I sent you a diff for the source, but not for the manpage. The diff for
 the latter follows.
 
 Ciao,
 Sheldon.
 
 Index: date.1
 ===================================================================
 RCS file: /home/ncvs/src/bin/date/date.1,v
 retrieving revision 1.31
 diff -u -d -r1.31 date.1
 --- date.1	1999/08/27 23:13:58	1.31
 +++ date.1	1999/10/25 11:49:14
 @@ -49,7 +49,7 @@
  .Op Fl t Ar minutes_west
  .Op Fl v Ns Ar [+|-]val Ns Op ymwdHMS
  .Ar ...
 -.Op Fl f Ar fmt Ar date | [[[[yy]mm]dd]HH]MM[\&.ss]
 +.Op Fl f Ar fmt Ar date | [[[[[cc]yy]mm]dd]HH]MM[\&.ss]
  .Op Cm + Ns Ar format
  .Sh DESCRIPTION
  .Nm Date
 @@ -74,7 +74,7 @@
  .Ar fmt
  as the format string to parse the date provided rather than using
  the default
 -.Ar [[[[yy]mm]dd]HH]MM[.ss]
 +.Ar [[[[[cc]yy]mm]dd]HH]MM[.ss]
  format.  Parsing is done using
  .Xr strptime 3 .
  .It Fl j
 @@ -168,6 +168,8 @@
  The canonical representation for setting the date and time is:
  .Pp
  .Bl -tag -width Ds -compact -offset indent
 +.It Ar cc
 +Century (either 19 or 20) prepended to the abbreviated year.
  .It Ar yy
  Year in abbreviated form (e.g. 89 for 1989, 06 for 2006).
  .It Ar mm
 


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-bugs" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199910251200.FAA94092>