You are not logged in.
Pages: 1
I have two locales set up, en_US and fi_FI. I want all the messages and ui to be in english, and dates, addresses etc to be in finnish.
Here is an example how it works now:
[risse@rissedesktop ~]$ locale
LANG=en_US.UTF-8
LC_CTYPE=fi_FI.UTF-8
LC_NUMERIC=fi_FI.UTF-8
LC_TIME=fi_FI.UTF-8
LC_COLLATE=fi_FI.UTF-8
LC_MONETARY=fi_FI.UTF-8
LC_MESSAGES=en_US.UTF-8
LC_PAPER=fi_FI.UTF-8
LC_NAME=fi_FI.UTF-8
LC_ADDRESS=fi_FI.UTF-8
LC_TELEPHONE=fi_FI.UTF-8
LC_MEASUREMENT=fi_FI.UTF-8
LC_IDENTIFICATION=fi_FI.UTF-8
LC_ALL=
[risse@rissedesktop ~]$ asdf
bash: asdf: komentoa ei löydyAs you can see, the error message for "asdf" is in finnish, even though the LANG and LC_MESSAGES are set to en_US.
So where is the locale for Bash terminal determined? I have tried googling this for hours now, and nothing seems to work.
Last edited by Risse (2019-05-18 05:38:02)
Offline
What does
echo $LANG say?
Maybe bash itself is running with previous locale settings.
Inofficial first vice president of the Rust Evangelism Strike Force
Offline
What does
echo $LANGsay?
Maybe bash itself is running with previous locale settings.
[risse@rissedesktop ~]$ echo $LANG
en_US.UTF-8
[risse@rissedesktop ~]$ asdf
bash: asdf: komentoa ei löydyOffline
What happens if you open a sub shell by running bash within the current shell? Does it behave the same way?
Last edited by schard (2019-05-17 07:18:48)
Inofficial first vice president of the Rust Evangelism Strike Force
Offline
What happens if you open a sub shell by running bash within the current shell? Does it behave the same way?
You mean like this?
[risse@rissedesktop ~]$ bash
[risse@rissedesktop ~]$ asdf
bash: asdf: komentoa ei löydy
[risse@rissedesktop ~]$ locale
LANG=en_US.UTF-8
LC_CTYPE=fi_FI.UTF-8
LC_NUMERIC=fi_FI.UTF-8
LC_TIME=fi_FI.UTF-8
LC_COLLATE=fi_FI.UTF-8
LC_MONETARY=fi_FI.UTF-8
LC_MESSAGES=en_US.UTF-8
LC_PAPER=fi_FI.UTF-8
LC_NAME=fi_FI.UTF-8
LC_ADDRESS=fi_FI.UTF-8
LC_TELEPHONE=fi_FI.UTF-8
LC_MEASUREMENT=fi_FI.UTF-8
LC_IDENTIFICATION=fi_FI.UTF-8
LC_ALL=No difference really.
Offline
Yes. Hm. I'm out of ideas here. I may try to reproduce this later.
You can also try to run the sub shell with explicitly set locales.
LANG=C bashor
LANG=en_US.UTF-8 bashrespectively.
Also, did you build both locales using locale-gen?
What's its output if you run it?
Last edited by schard (2019-05-17 07:26:14)
Inofficial first vice president of the Rust Evangelism Strike Force
Offline
Hey, localectl was the issue! I ran it, and got this:
[risse@rissedesktop ~]$ localectl status
System Locale: LANG=en_US.UTF-8
LANGUAGE=en_US:en:fi_FI
LC_CTYPE=fi_FI.UTF-8
LC_NUMERIC=fi_FI.UTF-8
LC_TIME=fi_FI.UTF-8
LC_COLLATE=fi_FI.UTF-8
LC_MONETARY=fi_FI.UTF-8
LC_PAPER=fi_FI.UTF-8
LC_NAME=fi_FI.UTF-8
LC_ADDRESS=fi_FI.UTF-8
LC_TELEPHONE=fi_FI.UTF-8
LC_MEASUREMENT=fi_FI.UTF-8
LC_IDENTIFICATION=fi_FI.UTF-8
VC Keymap: fi
X11 Layout: fiI then ran:
[risse@rissedesktop ~]$ localectl set-locale LANGUAGE=en_US.UTF-8Restarted the machine, and bash messages seem to be correct now:
[risse@rissedesktop ~]$ asdf
bash: asdf: command not foundThanks for the help schard!
Last edited by Risse (2019-05-17 07:38:47)
Offline
locale -a
cat /etc/locale.conf
tr '\0' '\n' < /proc/$$/environEdit: ninja'd by OP
Last edited by seth (2019-05-17 07:35:46)
Online
Please remember to mark your thread [SOLVED] (edit the title of your first post).
Offline
Pages: 1