From 82b7be2138d5343937bd74e191cb502f5748e8bb Mon Sep 17 00:00:00 2001 From: aszlig Date: Fri, 20 Jan 2023 00:27:54 +0100 Subject: profiles/base: Explicitly set locale categories The default locale is en_US.UTF-8, but this also comes with a 12 hour clock and a few other nuisances such as imperial units. So while I do prefer a German locale I don't want things to be in the German *language*, so setting something like de_DE.UTF-8 for LC_TIME doesn't fly very well, since it could result in something like "Freitag, 20. Januar". To cope with this, I used the C locale to make sure that we get a 24h clock and english week/month names. Similarily I do not want floats to be formatted with a comma. Signed-off-by: aszlig --- modules/user/aszlig/profiles/base.nix | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/modules/user/aszlig/profiles/base.nix b/modules/user/aszlig/profiles/base.nix index 681a044a..52649cbd 100644 --- a/modules/user/aszlig/profiles/base.nix +++ b/modules/user/aszlig/profiles/base.nix @@ -16,6 +16,18 @@ in { experimental-features = [ "nix-command" "flakes" ]; }; + i18n.defaultLocale = "en_US.UTF-8"; + i18n.extraLocaleSettings = { + LC_ADDRESS = "de_DE.UTF-8"; + LC_MEASUREMENT = "de_DE.UTF-8"; + LC_MONETARY = "de_DE.UTF-8"; + LC_NAME = "de_DE.UTF-8"; + LC_NUMERIC = "C.UTF-8"; + LC_PAPER = "de_DE.UTF-8"; + LC_TELEPHONE = "de_DE.UTF-8"; + LC_TIME = "C.UTF-8"; + }; + users.defaultUserShell = "/var/run/current-system/sw/bin/zsh"; networking.wireless.enable = false; -- cgit 1.4.1