History log of /freebsd-10-stable/bin/date/
Revision Date Author Comments
(<<< Hide modified files)
(Show modified files >>>)
323291 07-Sep-2017 marius

MFC: r321293

date: avoid crash on invalid time

PR: 220828
Approved by: re (kib)

313488 09-Feb-2017 ngie

MFC r289172,r290254:

r289172:

Refactor the test/ Makefiles after recent changes to bsd.test.mk (r289158) and
netbsd-tests.test.mk (r289151)

- Eliminate explicit OBJTOP/SRCTOP setting
- Convert all ad hoc NetBSD test integration over to netbsd-tests.test.mk
- Remove unnecessary TESTSDIR setting
- Use SRCTOP where possible for clarity

r290254:

Remove unused variable (SRCDIR)


/freebsd-10-stable/bin/cat/tests/Makefile
tests/Makefile
/freebsd-10-stable/bin/expr/tests/Makefile
/freebsd-10-stable/bin/ls/tests/Makefile
/freebsd-10-stable/bin/mv/tests/Makefile
/freebsd-10-stable/bin/pax/tests/Makefile
/freebsd-10-stable/bin/pkill/tests/Makefile
/freebsd-10-stable/bin/sh/tests/Makefile
/freebsd-10-stable/bin/sleep/tests/Makefile
/freebsd-10-stable/bin/test/tests/Makefile
/freebsd-10-stable/bin/tests/Makefile
/freebsd-10-stable/cddl/lib/tests/Makefile
/freebsd-10-stable/cddl/sbin/tests/Makefile
/freebsd-10-stable/cddl/tests/Makefile
/freebsd-10-stable/cddl/usr.bin/tests/Makefile
/freebsd-10-stable/cddl/usr.sbin/dtrace/tests/Makefile
/freebsd-10-stable/cddl/usr.sbin/tests/Makefile
/freebsd-10-stable/gnu/lib/tests/Makefile
/freebsd-10-stable/gnu/tests/Makefile
/freebsd-10-stable/gnu/usr.bin/diff/tests/Makefile
/freebsd-10-stable/gnu/usr.bin/tests/Makefile
/freebsd-10-stable/lib/atf/libatf-c++/tests/Makefile
/freebsd-10-stable/lib/atf/libatf-c++/tests/detail/Makefile
/freebsd-10-stable/lib/atf/libatf-c/tests/Makefile
/freebsd-10-stable/lib/atf/libatf-c/tests/detail/Makefile
/freebsd-10-stable/lib/atf/tests/Makefile
/freebsd-10-stable/lib/atf/tests/test-programs/Makefile
/freebsd-10-stable/lib/libc/tests/Makefile
/freebsd-10-stable/lib/libc/tests/Makefile.netbsd-tests
/freebsd-10-stable/lib/libc/tests/c063/Makefile
/freebsd-10-stable/lib/libc/tests/db/Makefile
/freebsd-10-stable/lib/libc/tests/gen/Makefile
/freebsd-10-stable/lib/libc/tests/gen/execve/Makefile
/freebsd-10-stable/lib/libc/tests/gen/posix_spawn/Makefile
/freebsd-10-stable/lib/libc/tests/hash/Makefile
/freebsd-10-stable/lib/libc/tests/inet/Makefile
/freebsd-10-stable/lib/libc/tests/locale/Makefile
/freebsd-10-stable/lib/libc/tests/net/Makefile
/freebsd-10-stable/lib/libc/tests/net/getaddrinfo/Makefile
/freebsd-10-stable/lib/libc/tests/regex/Makefile
/freebsd-10-stable/lib/libc/tests/rpc/Makefile
/freebsd-10-stable/lib/libc/tests/setjmp/Makefile
/freebsd-10-stable/lib/libc/tests/ssp/Makefile
/freebsd-10-stable/lib/libc/tests/stdio/Makefile
/freebsd-10-stable/lib/libc/tests/stdlib/Makefile
/freebsd-10-stable/lib/libc/tests/string/Makefile
/freebsd-10-stable/lib/libc/tests/sys/Makefile
/freebsd-10-stable/lib/libc/tests/termios/Makefile
/freebsd-10-stable/lib/libc/tests/time/Makefile
/freebsd-10-stable/lib/libc/tests/tls/Makefile
/freebsd-10-stable/lib/libc/tests/tls/dso/Makefile
/freebsd-10-stable/lib/libc/tests/ttyio/Makefile
/freebsd-10-stable/lib/libcrypt/tests/Makefile
/freebsd-10-stable/lib/libmp/tests/Makefile
/freebsd-10-stable/lib/libnv/tests/Makefile
/freebsd-10-stable/lib/libpam/libpam/tests/Makefile
/freebsd-10-stable/lib/librt/tests/Makefile
/freebsd-10-stable/lib/libthr/tests/Makefile
/freebsd-10-stable/lib/libthr/tests/dlopen/Makefile
/freebsd-10-stable/lib/libthr/tests/dlopen/dso/Makefile
/freebsd-10-stable/lib/libutil/tests/Makefile
/freebsd-10-stable/lib/msun/tests/Makefile
/freebsd-10-stable/lib/tests/Makefile
/freebsd-10-stable/libexec/atf/atf-check/tests/Makefile
/freebsd-10-stable/libexec/atf/atf-sh/tests/Makefile
/freebsd-10-stable/libexec/atf/tests/Makefile
/freebsd-10-stable/libexec/tests/Makefile
/freebsd-10-stable/sbin/devd/tests/Makefile
/freebsd-10-stable/sbin/dhclient/tests/Makefile
/freebsd-10-stable/sbin/growfs/tests/Makefile
/freebsd-10-stable/sbin/mdconfig/tests/Makefile
/freebsd-10-stable/sbin/tests/Makefile
/freebsd-10-stable/secure/lib/tests/Makefile
/freebsd-10-stable/secure/libexec/tests/Makefile
/freebsd-10-stable/secure/tests/Makefile
/freebsd-10-stable/secure/usr.bin/tests/Makefile
/freebsd-10-stable/secure/usr.sbin/tests/Makefile
/freebsd-10-stable/share/examples/tests/Makefile
/freebsd-10-stable/share/tests/Makefile
/freebsd-10-stable/tests/etc/Makefile
/freebsd-10-stable/tests/sys/mqueue/Makefile
/freebsd-10-stable/tests/sys/pjdfstest/tests/Makefile
/freebsd-10-stable/usr.bin/apply/tests/Makefile
/freebsd-10-stable/usr.bin/basename/tests/Makefile
/freebsd-10-stable/usr.bin/calendar/tests/Makefile
/freebsd-10-stable/usr.bin/cmp/tests/Makefile
/freebsd-10-stable/usr.bin/col/tests/Makefile
/freebsd-10-stable/usr.bin/comm/tests/Makefile
/freebsd-10-stable/usr.bin/cut/tests/Makefile
/freebsd-10-stable/usr.bin/dirname/tests/Makefile
/freebsd-10-stable/usr.bin/file2c/tests/Makefile
/freebsd-10-stable/usr.bin/grep/tests/Makefile
/freebsd-10-stable/usr.bin/gzip/tests/Makefile
/freebsd-10-stable/usr.bin/join/tests/Makefile
/freebsd-10-stable/usr.bin/jot/tests/Makefile
/freebsd-10-stable/usr.bin/lastcomm/tests/Makefile
/freebsd-10-stable/usr.bin/m4/tests/Makefile
/freebsd-10-stable/usr.bin/ncal/tests/Makefile
/freebsd-10-stable/usr.bin/printf/tests/Makefile
/freebsd-10-stable/usr.bin/sed/tests/Makefile
/freebsd-10-stable/usr.bin/tests/Makefile
/freebsd-10-stable/usr.bin/truncate/tests/Makefile
/freebsd-10-stable/usr.bin/uudecode/tests/Makefile
/freebsd-10-stable/usr.bin/uuencode/tests/Makefile
/freebsd-10-stable/usr.bin/xargs/tests/Makefile
/freebsd-10-stable/usr.bin/yacc/tests/Makefile
/freebsd-10-stable/usr.sbin/etcupdate/tests/Makefile
/freebsd-10-stable/usr.sbin/fstyp/tests/Makefile
/freebsd-10-stable/usr.sbin/newsyslog/tests/Makefile
/freebsd-10-stable/usr.sbin/nmtree/tests/Makefile
/freebsd-10-stable/usr.sbin/pw/tests/Makefile
/freebsd-10-stable/usr.sbin/sa/tests/Makefile
/freebsd-10-stable/usr.sbin/tests/Makefile
283258 21-May-2015 delphij

MFC r282608:

date(1): Make -r behave like GNU's version when the option can not be
interpreted as a number, which checks the file's modification time and
use that as the date/time value.

This improves compatibility with GNU coreutils's version of date(1).

270779 29-Aug-2014 ngie

MFC r269903:

Port date/bin/tests to ATF

Phabric: D545
Approved by: jmmv (mentor)
Submitted by: keramida (earlier version)
Sponsored by: Google, Inc
Sponsored by: EMC / Isilon Storage Division

265265 03-May-2014 dumbbell

date(1): Add "-R" flag to use RFC 2822 date and time output format [MFC]

As stated in the man page, this is equivalent to use "%a, %d %b %Y %T %z"
as the output format while LC_TIME is set to the "C" locale.

This is compatible with date(1) from the GNU core utilities.

This is an MFC of r264968 and r264970.

264483 14-Apr-2014 jmmv

MFC refactoring of the *.test.mk files.

- r263161 Make bsd.test.mk the only public mk fragment for the building of tests.
- r263172 Move FreeBSD Test Suite-specific code to a suite.test.mk file.
- r263204 Add some documentation for bsd.test.mk.
- r263217 Document support for TAP-compliant Perl test programs.

This is "make tinderbox" clean.

262951 09-Mar-2014 jmmv

Sync sh(1) in stable/10 to head.

This is a MFC of all the commits listed below.

My original goal of this change was to only merge the move of the tests
from tools/regression/bin/ into the new layout (which include tests for
sh(1) and other tools as well). However, doing so is tricky due to the
ongoing work in sh(1) and, especially, the many changes to its tests
since stable/10 was first branched.

Merging everything is the simplest way to achieve this goal and, as a
bonus point, we get various fixes and miscellaneous improvements into
the branch.

Per jilles' suggestion, I'm avoiding the merge of a couple of changes
(r256850 and r257506) that required depending kernel changes. I'm also
avoiding very recent changes that have not had a long enough time to be
validated in current.

This is "make tinderbox" clean.

r256735 sh: Remove one syscall when waiting for a foreground job.
r257399 sh: Allow trapping SIGINT/SIGQUIT after ignore because of '&'.
r257504 sh: Reorder union node to reduce its size on 64-bit platforms.
r257920 sh: Add a test case for would-be assignments that are not due to quoting.
r257929 sh: Properly quote alias output from command -v.
r258489 sh: Add tests for the </dev/null implicit in a background command.
r258533 sh: Add more tests for the </dev/null implicit in a background command.
r258535 sh: Make <&0 disable the </dev/null implicit in a background command.
r258776 sh: Prefer memcpy() to strcpy() in most cases. Remove the scopy macro.
r259047 sh: Split set -x output into a separate function.
r259210 Migrate tools/regression/bin/ tests to the new layout.
r259844 sh: Remove an unused variable.
r259846 sh: Initialize OPTIND=1 even if it came from the environment.
r259874 sh: Simplify code related to PPID variable.
r259946 sh: Don't check input for non-whitespace if history is disabled.
r260246 sh(1): Discourage use of -e.
r260506 Run the sh(1) and test(1) tests as unprivileged.
r260586 Mark the bin/pax tests as requiring perl.
r260634 Use TAP_TESTS_PERL to register the legacy_test in bin/pax.
r260635 Replace hand-crafted Kyuafiles with automatic generation.
r260654 sh: Remove SIGWINCH handler and just check for resize before every read.
r261121 sh: Add test for nested alias.
r261125 sh: Solve the alias recursion problem in a less hackish way.
r261141 sh: Do not depend on parse/execute split in new alias test.
r261160 sh: Add tests for alias names after another alias.
r261192 sh: Allow aliases to force alias substitution on the following word.
r262533 sh: Make expari() static.
r262565 sh: Do not corrupt internal representation if LINENO inner expansion fails.
r262697 sh: Simplify expari().

Reviewed by: jilles


/freebsd-10-stable/bin/Makefile
Makefile
tests
/freebsd-10-stable/bin/mv/Makefile
/freebsd-10-stable/bin/mv/tests
/freebsd-10-stable/bin/pax/Makefile
/freebsd-10-stable/bin/pax/tests
/freebsd-10-stable/bin/pax/tests/Makefile
/freebsd-10-stable/bin/pax/tests/legacy_test.pl
/freebsd-10-stable/bin/pax/tests/legacy_test.sh
/freebsd-10-stable/bin/sh/Makefile
/freebsd-10-stable/bin/sh/alias.c
/freebsd-10-stable/bin/sh/cd.c
/freebsd-10-stable/bin/sh/eval.c
/freebsd-10-stable/bin/sh/exec.c
/freebsd-10-stable/bin/sh/expand.c
/freebsd-10-stable/bin/sh/expand.h
/freebsd-10-stable/bin/sh/input.c
/freebsd-10-stable/bin/sh/jobs.c
/freebsd-10-stable/bin/sh/memalloc.c
/freebsd-10-stable/bin/sh/mystring.c
/freebsd-10-stable/bin/sh/mystring.h
/freebsd-10-stable/bin/sh/nodetypes
/freebsd-10-stable/bin/sh/parser.c
/freebsd-10-stable/bin/sh/parser.h
/freebsd-10-stable/bin/sh/redir.c
/freebsd-10-stable/bin/sh/sh.1
/freebsd-10-stable/bin/sh/show.c
/freebsd-10-stable/bin/sh/tests
/freebsd-10-stable/bin/sh/tests/Makefile
/freebsd-10-stable/bin/sh/tests/builtins/Makefile
/freebsd-10-stable/bin/sh/tests/builtins/command3.0.stdout
/freebsd-10-stable/bin/sh/tests/builtins/command5.0.stdout
/freebsd-10-stable/bin/sh/tests/builtins/command6.0.stdout
/freebsd-10-stable/bin/sh/tests/builtins/lineno2.0
/freebsd-10-stable/bin/sh/tests/parameters/Makefile
/freebsd-10-stable/bin/sh/tests/parameters/optind2.0
/freebsd-10-stable/bin/sh/tests/parser/Makefile
/freebsd-10-stable/bin/sh/tests/parser/alias11.0
/freebsd-10-stable/bin/sh/tests/parser/alias12.0
/freebsd-10-stable/bin/sh/tests/parser/alias13.0
/freebsd-10-stable/bin/sh/tests/parser/alias14.0
/freebsd-10-stable/bin/sh/tests/parser/alias15.0
/freebsd-10-stable/bin/sh/tests/parser/alias15.0.stdout
/freebsd-10-stable/bin/sh/trap.c
/freebsd-10-stable/bin/sh/trap.h
/freebsd-10-stable/bin/sh/var.c
/freebsd-10-stable/bin/sh/var.h
/freebsd-10-stable/bin/test/Makefile
/freebsd-10-stable/bin/test/tests
/freebsd-10-stable/bin/test/tests/Makefile
/freebsd-10-stable/bin/tests
/freebsd-10-stable/etc/mtree/BSD.tests.dist
/freebsd-10-stable/tools/regression/bin
256281 10-Oct-2013 gjb

Copy head (r256279) to stable/10 as part of the 10.0-RELEASE cycle.

Approved by: re (implicit)
Sponsored by: The FreeBSD Foundation


244538 21-Dec-2012 kevlo

Fix socket calls on error post-r243965.

Submitted by: Garrett Cooper


241737 19-Oct-2012 ed

More -Wmissing-variable-declarations fixes.

In addition to adding `static' where possible:

- bin/date: Move `retval' into extern.h to make it visible to date.c.
- bin/ed: Move globally used variables into ed.h.
- sbin/camcontrol: Move `verbose' into camcontrol.h and fix shadow warnings.
- usr.bin/calendar: Remove unneeded variables.
- usr.bin/chat: Make `line' local instead of global.
- usr.bin/elfdump: Comment out unneeded function.
- usr.bin/rlogin: Use _Noreturn instead of __dead2.
- usr.bin/tset: Pull `Ospeed' into extern.h.
- usr.sbin/mfiutil: Put global variables in mfiutil.h.
- usr.sbin/pkg: Remove unused `os_corres'.
- usr.sbin/quotaon, usr.sbin/repquota: Remove unused `qfname'.


239991 01-Sep-2012 ed

Rework all non-contributed files that use `struct timezone'.

This structure is not part of POSIX. According to POSIX, gettimeofday()
has the following prototype:

int gettimeofday(struct timeval *restrict tp, void *restrict tzp);

Also, POSIX states that gettimeofday() shall return 0 (as long as tzp is
not used). Remove dead error handling code. Also use NULL for a
nul-pointer instead of integer 0.

While there, change all pieces of code that only use tv_sec to use
time(3), as this provides less overhead.


208795 04-Jun-2010 brian

Explain that setting an absolute day value can fail and that the month should
usually be set first when using -v.

Adjust an example that sets the day to 30 before setting the month to 3 in
accordance with this approach as the example would always fail in February!

PR: 147354
MFC after: 2 weeks


202756 21-Jan-2010 ed

Remove stale references to utmp(5) and its corresponding filenames.

I removed utmp and its manpage, but not other manpages referring to it.


202193 13-Jan-2010 ed

Port everything in bin/ from utmp to utmpx.

date: use libc utmpx routines instead of the ones provided by libulog.
pax: don't depend on <utmp.h>


200157 05-Dec-2009 ed

Let date(1) use utmpx instead of logwtmp().

utmpx also has OLD_TIME/NEW_TIME messages, which seem to be intended for
the same purpose as how we call logwtmp() here.


176094 07-Feb-2008 ru

Don't reset DST computed by strptime() (when e.g. setting the
date via -f %s).

Reported by: Eugene Grosbein
Diagnosed by: Miguel Lopes Santos Ramos


170215 02-Jun-2007 remko

Correct the referenced securelevel document, it's now securelevel 7.

Pointed out by: ru


161469 20-Aug-2006 imp

Use strlcpy in place of strncpy + setting the last character NUL. To
be safe, memset the entire msg to '0'.


152547 17-Nov-2005 ru

-mdoc sweep.


151933 01-Nov-2005 trhodes

Note which options are not part of the standards.
Xref locale(1) and bump document date.

Reviewed by: keramida
No Objections: -standards


141846 13-Feb-2005 ru

Expand *n't contractions.


140353 16-Jan-2005 ru

Add the new standard EXIT STATUS section where appropriate.
Sort standard sections in the (documented) preferred order.


139969 10-Jan-2005 imp

/*- or .\"- or #- to begin license clauses.


139943 09-Jan-2005 ru

Scheduled mdoc(7) sweep.


133381 09-Aug-2004 yar

Change the behaviour of `-v' so that, e.g., stepping a month back
on March 31 won't take you to March 2 or 3 (now the result will
be the last day of February.)

In general, now stepping by months from the last days of the current
month A will take you to the very last day of the target month B if
B is shorter than A.

The previous version would just step to March 31 and rely on mktime(3)
to correct the date. Despite its simplicity, such way was counter-intuitive
to users and caused pain to shell script writers.

Noticed by: Igor Timkin <ivt at gamma dot ru>
Approved by: brian
MFC after: 2 weeks


132272 17-Jul-2004 alfred

Give the most awesome example of how to parse the output of date
back into epoch time. Everytime I'm asked to do this by someone I
have to spend about ten minutes recreating the same command line.
So record it under examples.


131505 03-Jul-2004 ru

Deal with double whitespace.


131484 02-Jul-2004 ru

Mechanically kill hard sentence breaks.


129294 16-May-2004 ru

DESCRIPTION was not updated for the new SYNOPSIS.


127964 06-Apr-2004 green

Give date(1) a much better SYNOPSIS section which is useful as more than
decoration. Further improvements are welcome, but at least this
is a separate of the various modes of operation date has, as well as
sectioning off the two deprecated options for settimeofday(tz) that
don't even apply to actual operation of date as such, anyway.


127958 06-Apr-2004 markm

Remove clause 3 from the UCB licenses.

OK'ed by: imp, core


126605 04-Mar-2004 mtm

Rev. 1.32 moved a comment to the wrong line. The hack refered to
in the comment applies to a decision that needs to be made in relation
to the year 2000.

In fact, that statement probably should be changed to be
more generic (getting the year from the current time perhaps). Otherwise,
starting in 2069 two digit year conversions in date(1) will start assuming
1900 instead of 2000. hehe.


124185 06-Jan-2004 obrien

Note the Linux required format.


120729 04-Oct-2003 dds

Check for write errors; report and exit with error value.


116282 13-Jun-2003 markm

Get this area compiling with the highest WARNS= that it works with.
Obsolete WFORMAT= junk also removed where possible.

OK'ed by: obrien
Tested on: sparc64, alpha, i386


111285 23-Feb-2003 ru

mdoc(7) police: markup laundry.


111104 18-Feb-2003 obrien

Add an example to help one manually set the date on one machine taking the out
put from another.


110390 05-Feb-2003 charnier

Enclose sccsid according to style(9).
udp/timed -> timed/udp


105396 18-Oct-2002 markm

Staticify for lint.


104410 03-Oct-2002 fanf

Fix some twelve hour clock braindamage. The range for hours is 0-23 not 1-12.

MFC After: 1 week


99109 30-Jun-2002 obrien

Consistently use __FBSDID


98062 09-Jun-2002 keramida

Use socklen_t for the length of a socket structure instead of `int'.

Reviewed by: mike


94850 16-Apr-2002 trhodes

s/CMOS/hardware as talked about on cvs-committers.

Suggested by: sheldonh
Approved by: bde
MFC after: 1 day


94787 15-Apr-2002 trhodes

Little nit pick in date(1) manual page, tell users which clock date(1)
sets

PR: 35606


91079 22-Feb-2002 markm

Fix warnings inspired by lint, a commercial lint and WARNS=4.


90166 04-Feb-2002 kris

Lock down with WFORMAT=1 except those directories with unfixed warnings.
Tested on i386 and alpha.


90108 02-Feb-2002 imp

o __P has been reoved
o Old-style K&R declarations have been converted to new C89 style
o register has been removed
o prototype for main() has been removed (gcc3 makes it an error)
o int main(int argc, char *argv[]) is the preferred main definition.
o Attempt to not break style(9) conformance for declarations more than
they already are.

Approved by: arch@, new style(9)


87323 04-Dec-2001 obrien

Default to WARNS=2. Binary builds that cannot handle this must explicitly
set WARNS=0.

Reviewed by: mike


85615 28-Oct-2001 dillon

Remove assumption that time_t is an int

MFC after: 1 day


81251 07-Aug-2001 ru

mdoc(7) police:

Avoid using parenthesis enclosure macros (.Pq and .Po/.Pc) with plain text.
Not only this slows down the mdoc(7) processing significantly, but it also
has an undesired (in this case) effect of disabling hyphenation within the
entire enclosed block.


79754 15-Jul-2001 dd

Remove whitespace at EOL.


77940 09-Jun-2001 ru

Simplify, with the power of new mdoc(7).


77934 09-Jun-2001 dd

Add -j to the usage string.

PR: 27986
Submitted by: Cyrille Lefevre <clefevre@redirect.to>


76749 17-May-2001 ru

Fix an off-by-hour bug when crossing Daylight Saving Time boundary.

PR: bin/27399
Submitted by: "Crist J. Clark" <crist.clark@globalstar.com>
MFC after: 3 days


74819 26-Mar-2001 fenner

Fix error reporting of delayed send errors.


74320 16-Mar-2001 dd

Make it clear that the -v option doesn't actually set the date.

PR: 24773
Approved by: nik


71195 17-Jan-2001 ben

Document the restrictions on changing times in high securelevels.

PR: 23502
Submitted by: Robert Boyd <rboyd@pokerspot.com>


70190 19-Dec-2000 ru

Prepare for mdoc(7)NG.


70056 15-Dec-2000 ru

Prepare for mdoc(7)NG.


69457 01-Dec-2000 brian

Exit if malloc() returns NULL

Submitted by: Chris Faulhaber <jedgar@fxp.org>


68935 20-Nov-2000 ru

mdoc(7) police: use the new features of the Nm macro.


64692 16-Aug-2000 imp

Don't explicitly declare optarg and optind. These are declared in
unistd.h, which is already included.


63950 28-Jul-2000 jwd

Try to clean the manpage up according to the mail from Sheldon
in committers (Message-Id: <72836.964344168@axl.ops.uunet.co.za>).

Also cleaned up a .Pq macro which was causing problems previous
to the original update I made.

Reviewed by: sheldonh
Approved by: jkh


63761 22-Jul-2000 jwd

Expand the -r option to support hex. Though undocumented, the -r
option already supported octal. Add a comment to the -r option
in the man page so it's a bit more specific.

Discrepancy brought to my attention by: sasdrq@unx.sas.com
Approved by: jkh


63417 18-Jul-2000 sheldonh

Fix one grammar problem which crept in from rev 1.40 to rev 1.42, and
one mdoc problem from rev 1.40 (unnecessarily populated Nm macro).


63224 15-Jul-2000 marko

Re-worded the description of the -r option

PR: 18792
Submitted by: Bob Johnson <bobj@atlantic.net>
Approved by: Alexander Langer <alex@freebsd.org>


63155 14-Jul-2000 alex

Now, the mdoc fixes, such as:
* remove hard sentence breaks
* use of Fl with Ar if argument available
* Dq -> Sq where better
* Ql -> Dq and Ql -> Fa where better
* include sections to Xr macro
* It Ar .ss -> It Ar ss


63153 14-Jul-2000 alex

As per request by sheldonh and others on IRC, seperate language and mdoc
fixes (very important in this case). Version 1.40 should be discarded.

This version includes the language diffs. To receive them, use
cvs diff [-u] -r 1.39 -r 1.41


63150 14-Jul-2000 alex

Fix several language, style and mdoc improvements (such as correct
usage of .Xr and removal of hard sentence breaks).

PR: 18880
Submitted by: Christian Weisgerber <naddy@unix-ag.uni-kl.de>
Obtained from: OpenBSD (in parts)


62208 28-Jun-2000 mpp

Grumble. The previous commit still had the wrong date in the
example. Oct 29 0:30 +3 hours is still Oct 29, no matter what the
DST setting is, and not Oct 30..


62207 28-Jun-2000 mpp

Typo fix.

PR: docs/19554
Submitted by: Kazuo Horikawa <horikawa@psinet.com>


61949 22-Jun-2000 brian

Mention the timezone where appropriate (for the -v option).
correct one of the -v options.


60836 23-May-2000 brian

Propogate the ``call mktime'' flag from adjwday() down to adjday().

Submitted by: Christian Weisgerber <naddy@mips.inka.de>


60718 19-May-2000 dbaker

Correct confusion and differentiate appropriately between GMT and UTC when
date is launched with the "u" argument. It now operates in the documented
manner.

Fix typo in date man page.

Submitted by: David McNett <nugget@slacker.com>


59175 12-Apr-2000 brian

Change -v so that variences in units of days or less are sensitive to
DST. Explain in more detail what date -v does when mixed with DST.

Previous code suggested broken by: wollman


59022 05-Apr-2000 brian

Always give mktime a timeval with tm_isdst set to -1, otherwise
things get a bit out-of-phase when we step backwards 1 hour from
between 0:00 and 1:00 on the first of the month following the
transition into Summer time. This is probably actually a bug
in mktime().

PR: 10963

If mktime() fails and 68 < year < 138, assume that the reason is
because of Summer time and adjust up or down according to our
adjusting context by one hour. This assumes that all DSTs are
multiples of 1 hour.

PR: 6223, 17750


57803 07-Mar-2000 sheldonh

Correct confusing description of the -r option.

PR: 17250
Submitted by: cjclark@home.com (Crist J. Clark)


57326 18-Feb-2000 alfred

Re-add "May" to the list of dates supported.

Approved by: jkh


55829 12-Jan-2000 brian

Fix various mandoc bugs


55225 29-Dec-1999 sheldonh

Back out previous commit and replace with a cleaner solution adapted
from the source attributed below. In particular, this removes a goto
inside a switch and replaces those horrendous ATOI macros with
something acceptable.

More clean-ups to come.

PR: bin/14151
Reported by: Christian Weisgerber <naddy@mips.rhein-neckar.de>
Obtained from: NetBSD


53082 10-Nov-1999 sheldonh

Allow the year to be specified with an optional century.

PR: 14472
Reported by: j_guojun@lbl.gov (Jin Guojun)


50471 27-Aug-1999 peter

$Id$ -> $FreeBSD$


50353 25-Aug-1999 jkh

Remove obsolete BUGS section which describes something which stopped
being relevant when we ripped out the BSD/VAX code.

Submitted by: Guy Harris <gharris@flashcom.net>


48214 25-Jun-1999 cracauer

Don't continue if parsing failed when -f is in use. Exit with nonzero value.


47129 14-May-1999 jmg

the month and three days are up for -hackers and the 24hrs for -committers.

add a -j flag that tells date not to try to set the date. This allows you
to use date as a userland interface to strptime.

example:
TZ=GMT date -j -f "%a, %d %b %Y %T %Z" "Sun, 08 Nov 1998 02:22:20 GMT" +%s

which is the standard format for Last-modified headers in HTTP requests.

only one to respond: eivind


46684 08-May-1999 kris

Various spelling/formatting changes.

Submitted by: Philippe Charnier <charnier@xp11.frmug.org>


46073 25-Apr-1999 imp

First set of fixes to keep egcs happy. These include {} around single
statement if blocks[*] when the else could be ambiguous, not defaulting
to int type and removal of some unused variables.

[*] This is explicitly allowed by style(9) when the single statement
spans more than one line.

Reviewed by: obrien, chuckr


44598 09-Mar-1999 brian

Support seconds with -v.
PR: 6308
Submitted by: Max Euston <meuston@jmrodgers.com>


42617 13-Jan-1999 danny

Example "19%y" changed to "%Y" to discourage poor usage.


41585 07-Dec-1998 bde

Don't put compiler warning flags in leaf Makefiles.


39925 03-Oct-1998 alex

Added missing #include <string.h>


36014 13-May-1998 phk

.Sh ENVIRONMENT VARIABLES -> .Sh ENVIRONMENT

PR: 6599
Reviewed by: phk
Submitted by: Josh Gilliam <josh@quick.net>


36006 13-May-1998 charnier

Restore Lite-2 sccsid. Restore include of sys/param.h.


35773 06-May-1998 charnier

Correct use of .Nm and other cosmetics. Add rcsid. Remove unused #inc.


35355 20-Apr-1998 rnordier

Spelling/typo fixes: (preceeded, friday).


32756 25-Jan-1998 jb

Cast a size_t to a long to avoid a gcc warning.


31921 21-Dec-1997 brian

Add (BSD) copyright headers.


31668 11-Dec-1997 brian

Put [+format] at the end of the usage message.
Make `date -?' output (pretty much) the same as
the man page
PR: 5269


30086 03-Oct-1997 wosch

Change example from US to international standard date notation.


30073 03-Oct-1997 danny

Back out suppress '\n' mod.


30021 01-Oct-1997 danny

Add the '-s' flag to the usage string.


30020 01-Oct-1997 danny

Add the ability to supress the '\n' at the end of the date printed.


30013 30-Sep-1997 joerg

Fix the broken `date HHMM.SS' handling.

PR: bin/4661
Submitted by: blank@sliphost37.uni-trier.de (Sascha Blank)


29329 13-Sep-1997 wosch

spelling corrections.

PR: docs/4450
Submitted by: josh@quick.net


28927 30-Aug-1997 jmg

fix misspelling

Submitted-by: Josh Gilliam

Closes PR:4425


28383 18-Aug-1997 brian

Hint at how to use TZ.
Submitted by: grog@lemis.com


28038 10-Aug-1997 brian

Remove forgotten debug statement.


28037 10-Aug-1997 brian

Add "-f fmt date" for specification of the
date using strptime(3).
Suggested by: Michael Smith <msmith@atrad.adelaide.edu.au>

Change mm & dd to MM & DD so that they don't
clash with the month.


28025 09-Aug-1997 brian

Change [-DMHW [+|-]val] to [-v [+|-]val[ymwdHM]]
Support Hours & Minutes
Add -Wall to Makefile


27874 04-Aug-1997 brian

Add [-DWMY] flags for date adjustment.
Discussed with: freebsd-hackers


26465 06-Jun-1997 charnier

Cosmetic change in usage string.


26362 02-Jun-1997 charnier

Off by 1 adjustment.


24976 16-Apr-1997 danny

Fix typo in comment; Document in an example that years beyond 1999
are handled; fix typo in same example.


24348 28-Mar-1997 imp

compare return value from getopt against -1 rather than EOF, per the final
posix standard on the topic.


23622 10-Mar-1997 guido

Fix buffer overflow


22988 22-Feb-1997 peter

Revert $FreeBSD$ to $Id$


21673 14-Jan-1997 jkh

Make the long-awaited change from $Id$ to $FreeBSD$

This will make a number of things easier in the future, as well as (finally!)
avoiding the Id-smashing problem which has plagued developers for so long.

Boy, I'm glad we're not using sup anymore. This update would have been
insane otherwise.


20413 14-Dec-1996 steve

Merge Lite2 mods, fix incorrect default string, cleanup
use of .Nm macros, and -Wall cleaning.


17891 29-Aug-1996 wosch

[HISTORY] command appeared in Version 1 AT&T UNIX
Obtained from: A Quarter Century of UNIX, Peter H. Salus, page 41


15068 06-Apr-1996 ache

For nonexisten time use proper diagnostic instead of bad format and usage


14575 12-Mar-1996 nate

Fix 'stutter' in manpage.
The man page for date(1) talks about "a a" maximum, not just
"a" maximum.

Submitted by: Simon Burge <simonb@telstra.com.au> via NetBSD GNATS


11738 23-Oct-1995 ache

Add setlocale(LC_TIME,...


10364 28-Aug-1995 dg

Correct the default format info to indicate "%+".


9944 05-Aug-1995 ache

Use %+ to print data using LC_TIME


8855 30-May-1995 rgrimes

Remove trailing whitespace.

Reviewed by: phk


7608 03-Apr-1995 joerg

date(1) didn't emit a final newline if the format had been specified
with `+'. This breaks tradition and violates Posix 1003.2.

Discoverd by: luigi@labinfo.iet.unipi.it (Luigi Rizzo)


5233 26-Dec-1994 bde

Obtained from: partly from 386BSD-0.1.2.4

Fix several bugs involving the obsolescent -d and -t options:
-d 0 and -t 0 were ignored
-t -600 was a usage error
-d 'atoi is not suitable for parsing args' and -t duh were not usage errors

Change some error messages to say which call to settimeofday failed.

Restore casts of NULL in function calls.

Finish conversion to using err() instead of perror().


3044 24-Sep-1994 dg

Added $Id$


2364 28-Aug-1994 ats

Reviewed by:
Submitted by:
Oops, overlooked another typo in this man page.


2359 28-Aug-1994 ats

Reviewed by:
Submitted by:
Correct two typos in the format string usages.


1557 26-May-1994 rgrimes

This commit was generated by cvs2svn to compensate for changes in r1556,
which included commits to RCS files with non-trunk default branches.