8 releases

0.2.4 Sep 5, 2024
0.2.3 Feb 9, 2024
0.2.2 Jan 1, 2024
0.2.1 Aug 29, 2023
0.1.0 Oct 14, 2022

#324 in Date and time

GPL-3.0-or-later

625KB
9K SLoC

C 7K SLoC // 0.2% comments AWK 1K SLoC // 0.2% comments Rust 735 SLoC // 0.1% comments Korn shell 681 SLoC // 0.1% comments Shell 31 SLoC // 0.1% comments

Time zone data generated at compile time from the IANA timezone database

Because the rules for timezone transitions around DST are frequently defined in terms of somewhat arcane rules such as "the last Sunday on or after October 20th", the build step uses the parse-zoneinfo crate to build a series of concrete timestamps and associated offsets for each timezone.
Unfortunately, this finite series of concrete timestamps covers only a finite period of time, even though the rules are usually defined for eternity. Since this crate is wholly reliant on parse-zoneinfo, it inherits the decision made there to be restricted to the time from 1800 to 2100. As a consolation, they offer that "it is not necessarily advisable to rely on offset changes so far into the future". This is fairly reasonable, considering that changes to timezones are occasionally announced just days in advance.

Finally, it must be said that without parse-zoneinfo, which is part of chrono, this crate, and by extension greg would not exist.

Dependencies

~0.7–1.6MB
~32K SLoC