Skip to content

Replace datetime and zoneinfo_compiled crates with chrono#867

Closed
ariasuni wants to merge 1 commit into
ogham:masterfrom
ariasuni:use-chrono
Closed

Replace datetime and zoneinfo_compiled crates with chrono#867
ariasuni wants to merge 1 commit into
ogham:masterfrom
ariasuni:use-chrono

Conversation

@ariasuni

@ariasuni ariasuni commented May 9, 2021

Copy link
Copy Markdown
Collaborator

After hours of pain trying to retro-engineer several libc including glibc, musl and Bionic (Android), I’ve come to the conclusion that it’s the wrong approach. But I couldn’t understand the mess that’s time and timezone handling in C, much less investigate every OS we would like exa to support.

Fortunately, chrono already provides us a nice Rust layer on top of all the nasty C platform-dependent code. Apart from Android, chrono also supports Windows.

  • Improve compatibility with other OSes, timezone are handled for us
  • Reduce significantly code handling and rendering time

Fix #620
Fix #712
Fix #856
Fix #1047

Close #846
Close #857

@dbeckwith

Copy link
Copy Markdown

I just started using NixOS and I'm seeing Unable to determine time zone: No such file or directory (os error 2) from exa v0.10.1. Does this PR cover fixing that?

@dbeckwith

Copy link
Copy Markdown

I guess it might be #856 which is fixed by this?

@dbeckwith

Copy link
Copy Markdown

Actually I was able to fix the error just by setting the time.timeZone NixOS config option.

@fkarg

fkarg commented Mar 26, 2022

Copy link
Copy Markdown

@dbeckwith I seem to have the same issue, though I have time.timeZone set properly

@ariasuni

Copy link
Copy Markdown
Collaborator Author

Please open an issue or comment under an existing issue so I can keep track of that properly.

@fkarg

fkarg commented Mar 26, 2022

Copy link
Copy Markdown

I found this PR after you linked it from my issue #1047 :)

- Improve compatibility with other OSes, timezone are handled for us
- Reduce significantly code handling and rendering time
@mrkline

mrkline commented Jun 17, 2022

Copy link
Copy Markdown

Is this blocked on anything? I would love to see it merged - exa continues to have trouble with the time zone on several of my machines due to how the TZ environment variable is handled. PRs to correct TZ handling per the glibc manual were closed in lieu of this PR. (see #911)

@txtsd

txtsd commented Feb 8, 2023

Copy link
Copy Markdown

This PR makes it work properly on my Arch machine. Can it be merged soon?

@tkapias

tkapias commented Mar 6, 2023

Copy link
Copy Markdown

Same for me on Debian testing, I never had this issue before, but I often use export TZ=:/etc/localtime in bash scripts. And today after some updates I-m now getting Unable to determine time zone: No such file or directory (os error 2) when I use exa -l. Please release this PR.

@StayPirate

Copy link
Copy Markdown

@ogham can you please merge/release this one?

@txtsd

txtsd commented Aug 24, 2023

Copy link
Copy Markdown

@ariasuni @ogham Please bump the priority up on this one.

@ariasuni

Copy link
Copy Markdown
Collaborator Author

Closing this, since exa is unmaintained (see #1243), and this has (finally 🎉) been merged in the active fork eza!

@ariasuni ariasuni closed this Sep 11, 2023
@ariasuni ariasuni deleted the use-chrono branch September 11, 2023 22:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

7 participants