Date
lastmod 2025-01-19created 2016-01-196 edits
Format
-
%Nnanoseconds (000000000..999999999) -
%sseconds since 1970-01-01 00:00:00 UTC
Current time
will return the number of seconds since the epoch.
returns the seconds and current nanoseconds.
will give you the number of milliseconds since the epoch - current seconds plus the left three of the nanoseconds.
Print milliseconds
To print the current time in milliseconds:
Calculating a date some days ago
Use the -d option.
Used in Answer:SteelScrap#Automatic compression bash script for cron.
See also
Favorite site
Pages that link here