Expand description
Wall-clock helpers — civil calendar without a chrono dependency.
omne-cli needs two stamp formats: YYYY-MM-DD for the volume
README (omne.md frontmatter) and YYYY-MM-DDTHH:MM:SSZ for every
entry in events.jsonl. Both are cheap if you have Howard Hinnant’s
public-domain civil-calendar algorithm, and we already do — but
Unit 11 duplicated the 15-line arithmetic into executor.rs without
sharing with commands::init::chrono_today. This module is the
single implementation; the two callers compose the format string
they need from the returned parts.
Structs§
- Civil
Utc - Broken-down UTC date/time from a Unix timestamp.
Functions§
- from_
system_ time - from_
unix_ seconds - Decompose a Unix second count into civil UTC parts. Public for deterministic unit tests that pin a specific instant.
- now_utc
- Current UTC instant as a
CivilUtc. Falls back to the Unix epoch if the system clock is before1970-01-01(noResult— a VM with a broken clock should see1970-01-01T00:00:00Z, which is loud enough to be noticed).