Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

I just have a custom locale for any UNIX-like systems I use. American English, UTF-8, 24-hour time, RFC-3339 dates, SI units, '.' decimal point, '_' thousands separator. I call it en_ENG, for the fictional land of Engineeristan.


I just use en_DK which (while not perfectly named) is exactly there to solve this.


That doesn't have `_` as the thousands separator. It uses ISO 8601 for date/times instead of RFC 3339 (so "2022-03-14T15:06:03 EDT" instead of "2022-03-14 15:06:03-04:00"), etc.

I just happen to want slightly different choices than it allows.


Mind to share your LC_ settings?


An explanation of all the valid fields can be found at [1]. Copy an existing locale, modify it to suit your needs. Don't forget to escape all characters as Unicode if you want it to support unicode. Compile & install as normal with localedef, add to `/var/lib/locales/supported.d`, run locale-gen, set the various `LC_` variables you want to use in `~/.profile` or `/etc/envionment` or whatever.

This[2] askubuntu answer goes into more detail.

[1] https://lh.2xlibre.net/locale/en_US/ [2] https://askubuntu.com/a/162714




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: