change system language
Hello,
I have a java program that has to use specific character encoding (baltic 1257). When i run this program on a UTF debian system, i get hieroglyphs from this program's output. If i change the system language to the one i need (lt-LT) - it works fine, but the whole system changes to this language and i don't want that. What i need to do is figure out a way (if such exists) to make this java process think that the system language is "lt-LT". Is this possible via some shell script or something like that? And do not suggest to convert this program to UTF instead of ASCII, because for some specific reasons, windows-1257 is required. |
Use
Code:
export LANG=lt_LT |
Thanks, i'll try that as soon as i can. Are there any other env variables that affect the language that could be exported?
|
I wish I knew the answer. I have this problem that sed fails on ISO-8859-1 content, so I have to run a pipe: iconv | sed | iconv. Example:
Code:
[yves@localhost java]$ echo $LANG Still, maybe the same can be done with java: java … | iconv -f UTF-8 -t lt_LT Yves. |
You can run
Code:
locale |
All times are GMT -5. The time now is 06:47 AM. |