The file /etc/enviroment has nothing to do with system locale and you have to edit LC_COLLATE=C.UTF-8. LC_ALL=C was back in the days but you using a rolling release.
When using sysvinit or openrc or something similar ...
your locales are created with locale-gen and /etc/locale.gen then passed to /etc/locale.conf and /etc/env.d/02locale
Here is an example ...
[~] cat /etc/locale.gen
C.UTF8 UTF-8
en_US ISO-8859-1
en_US.UTF-8 UTF-8
de_DE ISO-8859-1
de_DE@euro ISO-8859-15
de_DE.UTF-8 UTF-8
[~] cat /etc/locale.conf
# Configuration file for eselect
LANG="de_DE.utf8"
LC_COLLATE="C.UTF-8"
[~] cat /etc/env.d/02locale
# Configuration file for eselect
LANG="de_DE.utf8"
LC_COLLATE="C.UTF-8"
[~] ls -l /etc/env.d/02locale
lrwxrwxrwx 1 root root 14 1. Aug 20:10 /etc/env.d/02locale -> ../locale.conf
Verify that the selected locales are available by running locale -a and after availability is verified you can run source /etc/profile to update your system on the fly.
Note: locale will be saved to /usr/lib/locale/locale-archive and can be checked via localedef --list-archive.
When using systemd ...
- Get a list of available locales with
localectl list-locales.
- Set the desired locale via
localectl set-locale LANG=de_DE.utf8 and localectl set-locale LC_COLLATE=C.UTF-8 if needed.
- Check result with
localectl.