NavigationUser loginSpam?See spam posts on this site? If so, please don't reply to the spam! Instead, just report the URL to the webmaster. |
How to make Unicode (e.g UTF 8) to be the base of all charset related issues throughout the system on DebianThat is: How to make my [c,k]onsoles and terminals UTFcentric? Now, I am not asking of how to change a charset in certain app, but how to do it globally. Also, will this hamper the functionality of important commands like cp, tar, grep, etc. (I remeber that once cp simply ignored filenames with non-western alphabet) |
hmm...
I haven't done that for a long time but I think you do:
dpkg-reconfigure base-config
That doesn't work on my desktop for some reason so I'm not sure I've got that right.
Locales
Hi there
AFAIK, this is controlled by the locale and particularly by the default system locale.
If you set your locale to some UTF-8 locale (like en_GB.UTF-8) all applications will assume UTF-8 to be your default charset. So, like in the example locale given before, even though everything is in English (more or less like the C locale) you still have UTF-8 as a charset.
What exactly do you mean by globally? Globally for your user or globally for all users of the system?
If you want to have it on a per user basis, just make sure that the UTF-8 locales exist with
dpkg-reconfigure localesand assure that the user adds this to his .bash_profile (or whatever login shell configuration file his shell uses):
export LANG=en_GB.UTF-8. Even though the system default locale is some none-UTF-8 locale, everything such a user will read and write and see is UTF-8.To set the system default locale, also execute
dpkg-reconfigure localesand make sure that you select your favourite UTF-8 locale when it asks you about the system default locale. But again, this is not needed just to make UTF-8 "global" for one user, it will just affect what locale users will use that do not explicitly specify any locale themselves.That's it!
Cheers, Georg
Thanks georgos, pinniped! I
Thanks georgos, pinniped! I always forget the dpkg-reconfigure commands. Is there a list of important ones somewhere?
official Debian documentation
The Install documentation and other official docs on the Debian site actually tell you a lot. Way too much in fact - so most people forget it exists, but it's the place to look when you want to know things like "how do I set my timezone", "why is the stupid clock storing local time like WinDo$ does", and so on.
xfce4-terminal + ekg
I didn't want to make a new thread for this little question so I thought I might as well post in this one...
I've been trying to get polish characters to work in EKG (client for the Gadu Gadu IM network), I run ekg in xfce4-terminal and am unable to get them working. I have setup the LANG variable and I am able to type polish characters inside xfce4-terminal, but they don't work in EKG.
I have also tried installing rxvt-unicode and running EKG in that, and the characters display perfectly, which means that it's not EKG's fault, and it can't be xfce4-terminal's fault either since I can type in polish :|
Any ideas why it doesn't work in EKG under xfce4-terminal?
What is the LANG content of ekg started from xfce4-terminal
Hi there
Just to be sure, read out the LANG variable from this:
cat /proc/`pidof ekg`/environ
What does it say?
Cheers, Georg
LANG content of ekg started from xfce4-terminal
Seems to be ok, In EKG's configuration it has an aspell related configuration for the LANG. This is what is says:
I think that's alright, or should I change it to en_AU.UTF-8 (or pl_PL.UTF-8)? I don't think it has much significance since it's just spell checking...
Sorry for the late reply, I kind of gave up on this and only now resumed interest ;)
Edit: YAY!!! I'm not exactly what did it, but I change the default locale system wide to pl_PL (ISO-8559-2), NOT UTF, and it works :D Seems like the rest of the system uses English though, which is great because that's exactly what I wanted.
Edit2: Ok, some parts are in Polish :( crap, might have to play with that...
Edit3: Gah, seems the only way to get the Polish characters working is the have the locale set to pl_PL system wide. I tried running EKG using "LANG=pl_PL ekg" but it doesn't work.
Help? :(
Bug the author
EKG is not internationalized. It is hard coded to use ISO8859-2 and ignores LANG settings.
You should bug the author or contributors to fix it.
Change filenames & textfiles
Change filenames (train first, add '--notest' then you are ready.)
# convmv -f ISO-8859-1 -t UTF-8 -r /home/magnus/Documents/ --notest
Change textfiles
# iconv --from-code=ISO-8859-1 --to-code=UTF-8 ./oldfile.htm > ./newfile.html