Expand description
The job’s start time: \time, \day, \month, \year, the log
banner and the PDF creation date.
LuaTeX takes the time once, at startup: from SOURCE_DATE_EPOCH when it
is set (with or without FORCE_SOURCE_DATE), otherwise from the clock.
It converts it to local time, or to UTC with the -utc option. Dates in
PDF format carry the UTC offset (D:19700101010000+01'00' for epoch 0 in
Central Europe, D:19700101000000Z with TZ=UTC or -utc).
The local offset is found the way the C library finds it: from $TZ (a
zone name, optionally prefixed with :, or a POSIX TZ string), else from
/etc/localtime, reading the binary TZif files (RFC 8536) and their POSIX
TZ footer rules (POSIX.1, TZ variable) for times after the last
transition. Anything unreadable falls back to UTC.
Structs§
Functions§
- civil_
from_ days - The proleptic Gregorian date (year, month, day) of a day number.
- days_
from_ civil - Days since 1970-01-01 of a proleptic Gregorian date.
- local_
offset - Returns the local UTC offset (seconds east of UTC) at Unix time
t. - now
- The current time in seconds since the epoch.
- offset_
for_ tz - The offset at
tfor aTZvalue. - parse_
source_ date_ epoch - Interprets a
SOURCE_DATE_EPOCHvalue;Nonemeans “use the clock”. - source_
date_ epoch SOURCE_DATE_EPOCHfrom the environment, interpreted like LuaTeX does (seeparse_source_date_epoch).- startup_
random_ seed - The random seed of a job that does not set one.
- tzif_
offset - The UTC offset at
taccording to a TZif file.