home *** CD-ROM | disk | FTP | other *** search
-
- DIFFTIME(1) Amiga User's Manual DIFFTIME(1)
-
- NAME
- dur - calculate time differential between two times
-
- SYNOPSIS
- dur time1 [time2]
- dur "Sun Sep 29 10:20:30 CST 1991" "Sun Sep 14 11:12:13 1990"
- dur "Sun Sep 14"
-
- Note that quotation marks are needed where the time
- includes blanks!
-
- DESCRIPTION
- Dur is used to calculate the difference in time between two
- dates given in the same format as that used by the date
- command. If the second parameter is not supplied, the
- current system time is assumed. The time duration is
- provided in a fixed field output, containing the years, days,
- hours, minutes, and seconds of duration.
-
- Times given must be in system format, with the exception that
- timezone information is optional, and ignored if supplied.
- Time differential is always reported as the absolute positive
- difference. Times supplied must be valid system times, ie:
- there is no provision for times not understood by the date
- command, such as dates BC. If a year is not supplied, the
- current year is assumed. If a time is not supplied, 00:00:01
- is assumed. Thus, dur "Sun Sep 29" "Mon Sep 30" is valid.
- The Day of Week field is ignored, and may be specified as ???.
- Time fields may be overloaded, in order to make projections
- easier. As an example, ??? Oct 51 00:00:00 1991 is valid and
- is assumed to mean Nov 21. All month lengths and leap years
- are fully considered and significant.
-
- FILES
- difftime - program executable
-
- SEE ALSO
- date(1), asctime(1), localtime(1), ctime(1)
-
- BUGS
- All times provided are converted back into system internal
- times using the mktime() function, and therefore must be
- valid in the context of the system (see date(1)).
- A single year is considered to be a unit of 365 days, so that
- leap years are computed correctly. As an example, the
- difference between Oct 31, 1991 and Oct 31, 1992 is 1 year
- and 1 day (see your local dictionary).
-
- DIAGNOSTICS
- A usage summary is displayed in the absence of correct input
- values. It is sent to the standard error stream.
-
- COMPATIBILITY
- Fully compatible with all systems implementing the full ANSI
- library set.
-
- AUTHOR
- David Plummer plummer@hercules.cs.uregina.ca
-