X-Recipient: archive-cygwin@delorie.com
DomainKey-Signature: a=rsa-sha1; c=nofws; d=sourceware.org; h=list-id
	:list-unsubscribe:list-subscribe:list-archive:list-post
	:list-help:sender:date:from:reply-to:message-id:to:subject
	:in-reply-to:references:mime-version:content-type
	:content-transfer-encoding; q=dns; s=default; b=eSzY8TJP+rZQHZdN
	0CMeYNgrJsgO6v1pyZV34I7Ru5bERKaNFZqDv+1vyIvy0B/WJO1RTGvZZYHpSppO
	UkrNE2vcuoHuGyaynAXK/0qrRXH8AaZAnJFsnIlhEHExs2teW0vN5uwtRcZcNTin
	2C/UBv5JRwZNSTik3GRoNm27MCA=
DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=sourceware.org; h=list-id
	:list-unsubscribe:list-subscribe:list-archive:list-post
	:list-help:sender:date:from:reply-to:message-id:to:subject
	:in-reply-to:references:mime-version:content-type
	:content-transfer-encoding; s=default; bh=/8bcPhivcly2Jo4keRGRmm
	bVXU8=; b=Viu7EX8YQxbGUnZhGUzjKplNIvQJa3sipK9FNt9QkTAeN4WaXUZYIQ
	fAXE5rqC9nSmVZ6NwIjSp/hGlKKqA1vF+QQ0DCev7wuNyiyKam+QclpDAtQEtU/M
	6UWj5GLOKgyEfPvs0p6ZJ65dT0OqjIC9TiLu8pbg4+jBG1DhTWr2Y=
Mailing-List: contact cygwin-help@cygwin.com; run by ezmlm
List-Id: <cygwin.cygwin.com>
List-Subscribe: <mailto:cygwin-subscribe@cygwin.com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin@cygwin.com>
List-Help: <mailto:cygwin-help@cygwin.com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner@cygwin.com
Mail-Followup-To: cygwin@cygwin.com
Delivered-To: mailing list cygwin@cygwin.com
Authentication-Results: sourceware.org; auth=none
X-Virus-Found: No
X-Spam-SWARE-Status: No, score=-3.3 required=5.0 tests=AWL,BAYES_50,FREEMAIL_FROM,KAM_THEBAT,SPF_SOFTFAIL autolearn=no version=3.3.2
X-HELO: smtpback.ht-systems.ru
Date: Sat, 26 Apr 2014 03:13:28 +0400
From: Andrey Repin <anrdaemon@yandex.ru>
Reply-To: cygwin@cygwin.com
Message-ID: <568700949.20140426031328@yandex.ru>
To: "Larry Hall (Cygwin)" <cygwin@cygwin.com>
Subject: Re: How LANG environment variable is set?
In-Reply-To: <53599112.9080405@cygwin.com>
References: <53597E6B.1080207@alice.it> <53598885.5060708@acm.org> <53599112.9080405@cygwin.com>
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
X-IsSubscribed: yes

Greetings, Larry Hall (Cygwin)!

>> It looks like /etc/profile sets LC_ALL=C before running the scripts
>> in /etc/profile.d, then restores it to its original setting. This
>> prevents LANG getting set by lang.sh.
>>

> Good catch.  Yes, the latest version of base_files makes this change to
> the profile_d() function.  Looks like the easiest interim solution is to
> downgrade to base_files-4.1-2.

Actually, it might help to set LANG in user's profile instead.
I have this bit of code, working quite well:

case "$TERM" in
  xterm*)
    LANG=ru_RU.UTF-8
    ;;
  *)
    LANG=ru_RU.CP866
    ;;
esac

(mintty sets "xterm", so does xterm itself and other shells I connect to this
system with.)


--
WBR,
Andrey Repin (anrdaemon@yandex.ru) 26.04.2014, <03:11>

Sorry for my terrible english...


--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

