How to find the time in seconds from the Unix Epoch
Last updated at 3:36 am UTC on 20 September 2019
Often in computer programming we measure time in seconds (or (milli|micro|..)seconds ) from the Unix Epoch time , that is roughly from 1 Jan 1970 at 00:00:00 UTC.
In Squeak (tested Squeak 5.2) you find the current Epoch time as:
(DateAndTime now) asUnixTime.
To check the result, just type this in a Unix console. (tested FreeBSD 12.0)
$> date -u +%s
bye, [NMI]