-
Notifications
You must be signed in to change notification settings - Fork 41
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Use tzdb to support Windows hosts, too #107
Conversation
Thx your PR. @Kijewski
|
tz-rs's `TimeZone::local()` is only supported for Linux hosts, but will fail e.g. on Windows. Shadow-rs will fallback to use UTC dates, so it will still be usable on Window. tzdb's `local_tz()` bundles the Timezone Database, and works on Linux, Windows, MacOS, FreeBSD, and NetBSD. While having local datetimes on these host platforms is probably not particularly important, I still think it's a better user experience. tzdb itself uses tz-rs to make use of the timezone data.
Oops, fixed. |
Woh, so quick. 👍 |
Thx again. @Kijewski |
I was just checking Github before going to bed. :) Thank your for the library, too. It helps a lot to have that info handy in the logs, etc. |
It seems like
It’s probably a matter of adding iOS as a target in I can open another issue if needed @baoyachi. |
@appaquet Thx your report. I'll take a look later |
iana-time-zone 0.1.37 now includes iOS support. Thanks everyone. |
1 similar comment
iana-time-zone 0.1.37 now includes iOS support. Thanks everyone. |
tz-rs's
TimeZone::local()
is only supported for Linux hosts, but willfail e.g. on Windows. Shadow-rs will fallback to use UTC dates, so it
will still be usable on Window.
tzdb's
local_tz()
bundles the Timezone Database, and works on Linux,Windows, MacOS, FreeBSD, and NetBSD. While having local datetimes on
these host platforms is probably not particularly important, I still
think it's a better user experience.
tzdb itself uses tz-rs to make use of the timezone data.