Commit Graph

10 Commits

Author SHA1 Message Date
Heitor Toledo Lassarote de Paula
19bcaa2419 [#9] Fix compilation of executable on Windows
Problem: Compilation of the executable on Windows fails with 'Module
`GHC.IO.Encoding.Iconv' does not export `localeEncodingName'`

Solution: Check if we are on Windows, and don't import such module or
use `localeEncodingName` if it's the case.
2021-02-15 11:29:35 -03:00
Kirill Elagin
a6f79bf38d utf-troubleshoot: Fix build with GHC 8.2.2 2020-05-20 01:26:18 +03:00
Kirill Elagin
2a671c261b troubleshoot: Remove unneeded full stops 2020-05-15 16:22:53 +03:00
Kirill Elagin
c5221f4f1c troubleshoot: Detect Nix builds and show LOCALE_ARCHIVE 2020-05-15 16:22:53 +03:00
Kirill Elagin
f9aea084bb troubleshoot: Show listing locale-archive early
In case something bad happens with `localedef --list`, print the header
early to make it clear what failed.
Also, print the exception, if it happened.
2020-05-15 16:22:53 +03:00
Kirill Elagin
b5451aa606 utf8-troubleshoot: Only show relevant env vars 2020-05-15 16:22:53 +03:00
Kirill Elagin
6626507c16 troubleshoot: Add C stuff 2020-05-15 16:22:53 +03:00
Kirill Elagin
4074fe8f8d troubleshoot: Improve locale detection
* Use `localectl list-locales` if possible.
* Otherwise list `/usr/lib/locale` and try to use `localedef` to list
  `/usr/lib/locale/locale-archive`.
* Do not bother with `/usr/share/locale` as, it turns out, it is only used
  for localisations by third-party programs on Linux. Strangely, macOS
  seems to have actual locale definitions in there, but this tool is
  mostly aimed at Linux, since macOS installations are pretty uniform.
2020-04-21 14:05:53 +03:00
Kirill Elagin
bf51f1208b troubleshoot: Show basic system info 2020-04-21 01:51:15 +03:00
Kirill Elagin
b42026b313 troubleshoot: Make the troubleshooting tool 2020-04-21 01:40:36 +03:00