Manual Reference Pages  - accudate (1)

NAME

accudate - shows dates or elapsed times to the millisecond
 

CONTENTS

Description
Options
Examples
See Also
License
Copyright
Acknowledgements
Authors

SYNOPSIS

accudate [options...]

DESCRIPTION

accudate emits time and date related information with more accuracy than the standard date program. This information is written to stdout. It may be used to create time stamps or to measure elapsed times. Times are shown down to the millisecond but since the program itself requires finite time to run output may not be significant to the final digit.

accudate may be obtained as part of the drm_tools package from: http://sourceforge.net/projects/drmtools/

OPTIONS

[none] write time as YYYY-MM-DD:hh:mm:ss.lll to stdout. This fixed width, fixed field, format is easily sorted or parsed. The numeric fields are: YYYY year MM month DD day of the month hh hours (24 hour clock) mm minutes ss seconds lll milliseconds

-s Write time instead as YYYY-MM-DD hh:mm:ss.lll to stdout.

-touch Write time instead as YYYYMMDDhhmm.ss to stdout. For use with the Unix touch program.

-toff <seconds>
  Add <seconds> to the current time before emitting it. This value may be positive or negative. Common offsets are:hour=3600, day=86400, week=604800, year (365 days)=1536000. WARNING: consider leap years, daylight savings, time zones, and so forth!

-t0 Write time as seconds microseconds to stdout. These values may then be fed back into the program later with the -df or -ds flags to show elapsed times.

-df <seconds microseconds>
  Write elapsed time as DDDD-hh:mm.ss.lll to stdout. The value of <seconds microseconds> having been previously generated using the -t0 flag. Use this format to time very long events, up to 9999 days.

-ds <seconds microseconds>
  Write elapsed time as ssssss.lll to stdout. The value of <seconds microseconds> having been previously generated using the -t0 flag. Use this format to time very short events.

-h -help --help -? --??
  Print the help message. (Default - do not print help message.)

-i Emit version, copyright, license and contact information.( Default - do not emit information.)

EXAMPLES

% accudate -h
  List the the command line options.

% echo ‘accudate‘ message >>logfile
  Time stamp a log file with: 2002-12-12:09:56:01.123 message.

% STARTTIME=‘accudate -t0‘
% # other operations
% echo ‘accudate -df $STARTTIME‘ message >>logfile
  Log elapsed time as: 0000-00:01.56.456 message

% STARTTIME=‘accudate -t0‘
% # other operations
% echo ‘accudate -ds $STARTTIME‘ message >>logfile
  Log elapsed time as: 000016.456 message.

% STARTTIME=‘accudate -t0‘
% accudate -ds $STARTTIME
% accudate -ds $STARTTIME
% accudate -ds $STARTTIME
  Series of commands which may be used to estimate the smallest times which accudate can measure reliably.

% touch -t ‘accudate -toff -3600 -touch‘ filename
  Set the time on filename to one hour before the current time.

SEE ALSO

none

LICENSE

GNU General Public License 2

COPYRIGHT

Copyright (C) 2002, 2003, 2004, 2005, 2006 David Mathog and Caltech.

ACKNOWLEDGEMENTS

none

AUTHORS

David Mathog, Biology Division, Caltech <mathog@caltech.edu>


drm_tools accudate (1) 1.0.7 OCT 23 2006
Generated by manServer 1.07 from /usr/common/man/man1/accudate.1 using man macros.