SlackwareThis Forum is for the discussion of Slackware Linux.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Supported "locale" are here:
=> /usr/share/locale/
Code:
$ locale -a
I don't get it though! My /etc/profile.d/lang.sh is set to LANG=en_US.UTF-8
Code:
#!/bin/sh
# Set the system locale. (no, we don't have a menu for this ;-)
# For a list of locales which are supported by this machine, type:
# locale -a
# en_US.UTF-8 is the Slackware default locale. If you're looking for
# a different UTF-8 locale, be aware that some of them do not include
# UTF-8 or utf8 in the name. To test if a locale is UTF-8, use this
# command:
#
# LANG=<locale> locale -k charmap
#
# UTF-8 locales will include "UTF-8" in the output.
export LANG=en_US.UTF-8
Quote:
bash-5.2# set | grep LC
LC_ALL=
LC_COLLATE=C
LC_MONETARY=en_MT.UTF-8
MAILCHECK=60
bash-5.2#
Am i completely wrong or, this shows that the line 'LC_MONETARY is set to en_MT.UTF-8 (what is LC-MONETARY)
Should i edit the 'LC_MONETARY' line in this case? if so, where is it?
$ LC_MONETARY=en_MT.UTF-8 python
Python 3.11.9 (main, Apr 2 2024, 13:43:44) [GCC 13.2.0] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import locale
>>> locale.setlocale(locale.LC_ALL, '')
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/usr/lib64/python3.11/locale.py", line 627, in setlocale
return _setlocale(category, locale)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^
locale.Error: unsupported locale setting
>>>
My 'locale' is set to the correct language
Code:
#!/bin/sh
# Set the system locale. (no, we don't have a menu for this ;-)
# For a list of locales which are supported by this machine, type:
# locale -a
# en_US.UTF-8 is the Slackware default locale. If you're looking for
# a different UTF-8 locale, be aware that some of them do not include
# UTF-8 or utf8 in the name. To test if a locale is UTF-8, use this
# command:
#
# LANG=<locale> locale -k charmap
#
# UTF-8 locales will include "UTF-8" in the output.
export LANG=en_US.UTF-8
That variable says something about how values and currencies should be displayed. Different countries might have different preferences like:
1 000,00 €
1,000.00 $
Quote:
Originally Posted by however
Should i edit the 'LC_MONETARY' line in this case? if so, where is it?
On my Slackware 15.0 system it has not been set at all. On your system, it has probably been set in some login file of yours or possibly by some desktop environment.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.