0

I'm running the following setup

  • Operating System: Debian GNU/Linux 10
  • KDE Plasma Version: 5.14.5

(I'm also using Awesome WM if that's relevant)

Following the Debian wiki, I've run dpkg-reconfigure locales to generate locales and set my /etc/default/locale to the following:

LANG="en_US.UTF-8"
LANGUAGE="en_US:fr"
LC_CTYPE="fr_FR.UTF-8"
LC_NUMERIC="en_US.UTF-8"
LC_TIME="fr_FR.UTF-8"
LC_COLLATE="fr_FR.UTF-8"
LC_MONETARY="fr_FR.UTF-8"
LC_MESSAGES="en_US.UTF-8"
LC_PAPER="fr_FR.UTF-8"
LC_NAME="fr_FR.UTF-8"
LC_ADDRESS="fr_FR.UTF-8"
LC_TELEPHONE="fr_FR.UTF-8"
LC_MEASUREMENT="fr_FR.UTF-8"
LC_IDENTIFICATION="fr_FR.UTF-8"

That is, I'm trying to get every information in english, except for dates, measurements, etc.

When I type locale, I get this:

LANG=fr_FR.UTF-8
LANGUAGE=en_US:fr
LC_CTYPE=fr_FR.UTF-8
LC_NUMERIC=en_US.UTF-8
LC_TIME=fr_FR.UTF-8
LC_COLLATE=fr_FR.UTF-8
LC_MONETARY=fr_FR.UTF-8
LC_MESSAGES=en_US.UTF-8
LC_PAPER=fr_FR.UTF-8
LC_NAME=fr_FR.UTF-8
LC_ADDRESS=fr_FR.UTF-8
LC_TELEPHONE=fr_FR.UTF-8
LC_MEASUREMENT=fr_FR.UTF-8
LC_IDENTIFICATION=fr_FR.UTF-8
LC_ALL=

When I type locale -a, I get:

C
C.UTF-8
en_US.utf8
fr_FR.utf8
POSIX

As you can see, LANG is set to fr_FR.UTF-8, while I'd like it to be en_US.UTF-8. Is there something wrong with my /etc/default/locale syntax ? What could possibly override its content and be considered at login time instead ? KDE regional settings seem to be only american english (and KDE menus/windows are indeed in english).

  • You need to add what «locale -a» outputs – Rusi Feb 16 at 11:15
  • @Rusi just edited my post to add this output. – Raphaël Ventura Feb 18 at 17:10
  • Welcome , could you add the output of grep 'LANG\|LC' ~/.bashrc – GAD3R Feb 18 at 17:47
  • Check your pam_environment? – Rusi Feb 19 at 3:03
  • Hi @GAD3R, nothing except this little commented hacky line: # LANG="en_US.UTF-8"; export LANG (See my answer to Yasien Dwieb below) – Raphaël Ventura Feb 20 at 15:26
1

Well, after @GAD3R's comment, I realized my LANGUAGE variable setting wasn't really consistent with what I wanted : english messages by default, french units / dates, etc. I set it back to only en_US, and something weird happened : when logging into awesome WM, the output of locale was what I'd expected and everything worked fine, but not when logging into KDE Plasma.

With Plasma, I still had LANGUAGE=en_US:fr printed in the locale output ! I finally checked the plasma regional settings, and spotted that there was no default language set. I set it to 'American English', checked the 'Detailed settings' checkbox in the 'Formats' menu (everything was already filled in accordance to the configuration file), logged out and back in and the problem was solved.

I guess that filling stuff inside Plasma settings was necessary, even if everything had been configured through the /etc/ config file already.

| improve this answer | |
0

You can place this in your .bashrc file as follows

export LANG="en_US.UTF-8"

And put remaining values as so

| improve this answer | |
  • Thanks. I know I can set the environment variable through a bashrc file, but this sounds hacky and I'd rather know why some of the variables from my /etc file are considered while LANG is overriden. – Raphaël Ventura Feb 10 at 16:04

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.