Home| general |src.bin|task| invtime Index

invtime

Syntax
invtime --help
invtime [-c columns...] [name]
invtime -d -sd yyyymmdd [-c columns...] [name]
Synopsis

Convert back from second of epoch or second of day to regular time.

Options
--helpprint the help message and exit.
--versionprint the RST version number and exit.
-c columnsprint only the columns given by the comma separated list columns.
-dthe time is given as seconds of day.
-sd yyyymmddset the start date to the value of yyyymmdd.
namefilename of the ASCII file, if this is omitted the file will be read from standard input.
Description

Convert from a time expressed as seconds from 0:00UT January 1, 1970, or seconds from the start of a day, in a text file, back to the full Universal Time.

The reformatted text file is written to standard output.

Each line of the data file should consist of a single record. Entries in the record should be space or tab separated and the first number represent the date and time of the record expressed either as seconds from epoch or seconds from start of day:

seconds data...

The remainder of the line is the record data.

The program converts the time back to a full representation of year, month, day, hour, minute and seconds. if the "-d" option is specified then the "-sd" option can be used to set the start date of the data.

The converted time followed by the remainder of the record data is written to standard output.

Examples
invtime data.txt > data.2.txt

Convert the times in the file "data.txt" to a full reprentation of year, month, day, hour, minute and second. The output is written to the file "data.2.txt".

invtime -d -sd 20040830 data.txt > data.2.txt

Convert the times in the file "data.txt" to a full representation of year, month, day, hour, minute, and seconds. The input file is assumed to contain seconds from the start of the day and the date is set to 30th August, 2004. The output is written to the file "data.2.txt".