What locale/codeset do you run your slackware box on?
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.
View Poll Results: What locale/codeset do you use?
UTF-8
73
85.88%
ISO8859-1
9
10.59%
Other ISO8859-*
2
2.35%
Other
3
3.53%
Multiple Choice Poll. Voters: 85. You may not vote on this poll
What locale/codeset do you run your slackware box on?
I know most distro's tend to be pre-configured for UTF-8 these days, but I've been giving this some thought of late and was curious how many slackers have made the jump to unicode, and if so, have you encountered any incompatible programs.
Also, I improve the performance of all my text-parsing utilities (sort, grep, etc) by setting LANG=C and LC_ALL=C. It's like the modern equivalent to the old PC's "Turbo" switch.
fr_FR.utf8. This doesn't prevent me to write "LANG=C <something>" and maybe LC_COLLATE=C [1] when <something> is happier or faster with that, of course. To properly display the man pages encoded in UTF-8, I've in ~/.bashrc:
Code:
alias uman="GROFF_ENCODING=utf8 man"
There still remain a few _not_English_man_ pages_ in legacy encodings, but what can I do?
Also, I can understand that people speaking and reading only in English be not that much interested by UTF8, though but a very few performance costs, or issues with legacy utilities, as ASCII is functionally a subset of UTF-8 I hardly see any drawback even for them using UTF-8.
[1] I'll add LC_CTYPE if you insist, though I rarely need to set LANG to anything other than fr_FR.utf8, and practically never find the need to set other internationalization variables as defined in POSIX' xbd volume.
Last edited by Didier Spaier; 08-05-2014 at 04:34 AM.
Running in utf-8 and then overriding to LANG=C for performance is fine as long as you know there are no multibyte characters in the input data, or that you are doing no character specific operations on it. But, as the following shows, it can break things:
I've got locale set to en_GB. On my laptop, anyway, (where I am now). But I'm pretty sure I've got en_GB.UTF-8 on my desktop - I'll check later.
I'm using a unicode font in the console (Lat2-Terminus16), because it looks better than the default. Nothing bad has happened yet. But it probably will now I've mentioned it.
I don't think I'd be inclined to do this very often, if at all.
Nothing is broken IMO. You tell wc that you feed it with one byte characters, give it 7 bytes, then it answers you that it founded 7 characters. I don't see anything wrong here.
Last edited by Didier Spaier; 08-05-2014 at 05:24 AM.
The breakage I was referring to is in the usage: the inappropriate override of LANG=C. I thought that was obvious from the context of what I posted, but I guess not. As you say, the 'wc' utility is clearly not broken, working as designed, and doing exactly what I told it to.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.