From: Andrej Borsenkow <borsenkow.msk@sni.de>
To: zsh-workers@math.gatech.edu
Subject: zsh-2.6.b19: handling of locale probably wrong?
Date: Thu, 6 Jun 1996 12:46:10 +0400 (MOW) [thread overview]
Message-ID: <Pine.SV4.3.93.960606123343.18409B-100000@itsrm1> (raw)
I just started to work with zsh, and already am fond of it. However, one
small problem:
zsh is using value of LANG to set locale (langsetfn()). It means, that as
long as zsh sees LANG it sets *complete* locale to the value of LANG.
I don't have standards at hand, but according to man pages on our system
(and as far as I know it is consistent with XPG and POSIX) the locale is
set to the value of (in decreasing precedence);
LC_ALL
LC_CTYPE, LC_MESSAGES, LC_COLLATE, ...
LC_LANG.
that is, if LC_ALL is set, it overrides any other settings;
if any category is set, it overrides value of LANG;
otherweise use value of LANG.
My problem is, I (and many others as well) using LANG=english and
LC_CTYPE, LC_COLLATE=russian. So I get messages, dates, times and so on in
english, which I prefer, while still have correct character handling.
zsh sets it correct at first (setlocale(LC_ALL,"")), but it seems that
after it sees LANG, it resets the *complete* locale to english
(setlocale(LC_ALL,<value of LANG>) in langsetfn()), LC_CTYPE and
LC_COLLATE including.
Probably, it wouldn't be so bad idea to implement correct hadling of it?
That is, check for existence of LC_ALL and LC_* befor setting LANG?
I am not so nuch deep in sources; but if you tell, how to check for the
variable value (and get it) I could make the patches.
thanks in advance
-------------------------------------------------------------------------
Andrej Borsenkow Fax: +7 (095) 252 01 05
SNI ITS Moscow Tel: +7 (095) 252 13 88
NERV: borsenkow.msk E-Mail: borsenkow.msk@sni.de
-------------------------------------------------------------------------
reply other threads:[~1996-06-06 8:56 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=Pine.SV4.3.93.960606123343.18409B-100000@itsrm1 \
--to=borsenkow.msk@sni.de \
--cc=zsh-workers@math.gatech.edu \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.vuxu.org/mirror/zsh/
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).