[Error] HOST_LOCALE not obtained correctly when /etc/locale.conf doesn't exist
- 主要言語
- Go
- スター
- 13k
- フォーク
- 541
- 平均マージ
- 20時間 47分
- マージ済み PR(30日)
- 4
説明
**Describe the bug**
Currently, when creating a distrobox on a host system where /etc/locale.conf does not exist, the container's LANG variable will be set to a locale that's not available in the container.
For example, in gentoo, the locale is set in [/etc/env.d/02locale](https://wiki.gentoo.org/wiki/Handbook:AMD64/Installation/Base#Locale_selection) instead of /etc/locale.conf, which the distrobox-init script never reads, and instead initializes the HOST_LOCALE variable to a fallback value.
I'd suggest having distrobox pick up the LANG variable from the host environment, instead of trying to parse host system configuration. Alternatively, distrobox should provide a way to set HOST_LOCALE in the configuration, and set the container's LANG variable to the same value.
This is a follow-up of https://github.com/89luca89/distrobox/issues/1743
コントリビューションガイド
評価
この issue はまだ評価されていません。