FAQ Search Today's Posts Mark Forums Read
» Video Reviews

» Linux Archive

Linux-archive is a website aiming to archive linux email lists and to make them easily accessible for linux users/developers.


» Sponsor

» Partners

» Sponsor

Go Back   Linux Archive > Gentoo > Gentoo User

 
 
LinkBack Thread Tools
 
Old 09-10-2012, 03:24 AM
Dale
 
Default Having the possibility to set the system-wide locale settings

Chris Stankevitz wrote:
> Hello,
>
> Section 8c of the handbook tells me:
>
> ===
>
> You now have the possibility to set the system-wide locale settings in
> the /etc/env.d/02locale file:
>
> ===
>
> Code Listing 3.8: Setting the default system locale in /etc/env.d/02locale
> LANG="de_DE.UTF-8"
> LC_COLLATE="C"
>
> ===
>
> Q1: Do I have the possibility to set the system-wide locale settings?
> A1: YES [I knew the answer to this one!]
>
> Q2: Should I?
> A2: ?
>
> Q3: If yes, what should I set them to? [The example sets them to a
> magical value that seems to be related to code listing 3.6, but it is
> not exactly the same. I am in the united states and I speak english
> if that helps answer this one.]
> A3: ?
>
> Thank you!
>
> Chris
>
> PS: In case it is not clear already I have no idea what a locale is
> and have no preference or what it is so long as gentoo and all my apps
> are happy.
>
>

I think my settings would work for you. This is what is in my file:

LANG="en_US.UTF8"
LC_ALL="en_US.UTF8"

It works fine for me. Everything is in English as in American not the
others. lol

Dale

:-) :-)

P. S. Welcome to Gentoo and the world of constantly learning. Just
when you learn something, something changes and you get to learn it all
over again. :/

--
I am only responsible for what I said ... Not for what you understood or how you interpreted my words!
 
Old 09-10-2012, 05:05 AM
Joshua Murphy
 
Default Having the possibility to set the system-wide locale settings

On Sun, Sep 9, 2012 at 9:47 PM, Chris Stankevitz
<chrisstankevitz@gmail.com> wrote:
> Hello,
>
> Section 8c of the handbook tells me:
>
> ===
>
> You now have the possibility to set the system-wide locale settings in
> the /etc/env.d/02locale file:
>
> ===
>
> Code Listing 3.8: Setting the default system locale in /etc/env.d/02locale
> LANG="de_DE.UTF-8"
> LC_COLLATE="C"
>
> ===
>
> Q1: Do I have the possibility to set the system-wide locale settings?
> A1: YES [I knew the answer to this one!]
>
> Q2: Should I?
> A2: ?
>
> Q3: If yes, what should I set them to? [The example sets them to a
> magical value that seems to be related to code listing 3.6, but it is
> not exactly the same. I am in the united states and I speak english
> if that helps answer this one.]
> A3: ?
>
> Thank you!
>
> Chris
>
> PS: In case it is not clear already I have no idea what a locale is
> and have no preference or what it is so long as gentoo and all my apps
> are happy.

A 'locale' is a collection of character set, language, date/time
format, currency format, etc [1]. For US English, Dale's response
pretty well covers it. As for whether you 'should' set a system-wide
locale, it's dependent on the system. If it's a system used
exclusively by people with a common choice of locale, it potentially
saves on per-user configuration. If it's a system used by people from
around the globe, it can break their expectations of how a 'default'
system should act before they configure their own account for their
own locale. I believe, in the event a locale isn't specified, it
defaults to "POSIX". Of course, all of this also depends on the
software involved actually honoring the setting, but luckily enough
(for selfish people like me, that is), US English tends to be the de
facto standard even when things don't honor the locale.

[1] http://www.linuxtopia.org/online_books/programming_books/gnu_libc_guide/Effects-of-Locale.html

--
Poison [BLX]
Joshua M. Murphy
 
Old 09-10-2012, 06:17 PM
Chris Stankevitz
 
Default Having the possibility to set the system-wide locale settings

On Sun, Sep 9, 2012 at 8:24 PM, Dale <rdalek1967@gmail.com> wrote:
> LANG="en_US.UTF8"
> LC_ALL="en_US.UTF8"

Dale,

Thank you, I used the same.

> P. S. Welcome to Gentoo and the world of constantly learning. Just
> when you learn something, something changes and you get to learn it all
> over again. :/



Chris
 
Old 09-10-2012, 06:20 PM
Chris Stankevitz
 
Default Having the possibility to set the system-wide locale settings

On Sun, Sep 9, 2012 at 10:05 PM, Joshua Murphy <poisonbl@gmail.com> wrote:
> A 'locale' is a collection of character set, language, date/time
> format, currency format, etc

Josh,

Thank you. I now understand what a "locale" is. It is surprising to
me that the string "en_US.UTF8" tells the OS about currency,
date/time, etc. I always thought "UTF8" was just a "character
encoding" (not really sure what that is either but I would not have
guessed that UTF8 describes where the commas go in a currency).

Thanks again,

Chris
 
Old 09-10-2012, 11:12 PM
Paul Hartman
 
Default Having the possibility to set the system-wide locale settings

On Mon, Sep 10, 2012 at 1:20 PM, Chris Stankevitz
<chrisstankevitz@gmail.com> wrote:
> On Sun, Sep 9, 2012 at 10:05 PM, Joshua Murphy <poisonbl@gmail.com> wrote:
>> A 'locale' is a collection of character set, language, date/time
>> format, currency format, etc
>
> Josh,
>
> Thank you. I now understand what a "locale" is. It is surprising to
> me that the string "en_US.UTF8" tells the OS about currency,
> date/time, etc. I always thought "UTF8" was just a "character
> encoding" (not really sure what that is either but I would not have
> guessed that UTF8 describes where the commas go in a currency).


It doesn't, really. The locale code is typically composed of the format:

language_region.encoding

So for en_US.UTF8, language (en = English), region (US = United
States), and encoding (UTF8 = Unicode). In this case the region code
is where it will get the information about currency format etc.

Some places also have an additional script identifier (languages which
can be written in both Latin and Cyrillic, for example), and other
modifiers are allowed to specify currencies, calendar formats, number
system, etc. which might not be easily implied simply by knowing the
language and country.
 

Thread Tools




All times are GMT. The time now is 01:16 PM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.
Copyright 2007 - 2008, www.linux-archive.org