From SpectLog
Jump to: navigation, search


The format specification is in man 1 date.

Examples

Print timestamp with nanoseconds (i.e. 2013-02-11T22-28-03.500059023):

date "+%Y-%m-%dT%H-%M-%S.%N"


Display specified date YYYYMMDD (i.e. 20130211) in another format:

date "+%Y-%m-%d" -d 20130211


Show time in seconds since UNIX epoch:

date "+%s"