X-Recipient: archive-cygwin@delorie.com
X-SWARE-Spam-Status: No, hits=-1.9 required=5.0 	tests=AWL,BAYES_00,SARE_MSGID_LONG40,SPF_PASS
X-Spam-Check-By: sourceware.org
MIME-Version: 1.0
In-Reply-To: <4AA72295.7010401@fmail.co.uk>
References: <4AA72295.7010401@fmail.co.uk>
Date: Wed, 9 Sep 2009 20:31:07 +0100
Message-ID: <416096c60909091231p3bbe0ef2p2edb99a622702b43@mail.gmail.com>
Subject: Re: Help needed getting unicode working in bash
From: Andy Koppe <andy.koppe@gmail.com>
To: cygwin@cygwin.com
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: quoted-printable
X-IsSubscribed: yes
Mailing-List: contact cygwin-help@cygwin.com; run by ezmlm
Precedence: bulk
List-Id: <cygwin.cygwin.com>
List-Unsubscribe: <mailto:cygwin-unsubscribe-archive-cygwin=delorie.com@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

2009/9/9 Kit Johnson:
> I'm just getting started with cygwin and really enjoying the linux-like
> functionality under windows. =C2=A0I have one major problem which is disp=
laying
> unicode filenames in bash.
>
> To be specific about my problem, I do not need to type unicode under bash=
, I
> simply want to be able to list them (using ls) and archive them (using ta=
r).
> =C2=A0Currently all I get is this: =C2=A0"ls: cannot access ?????????????=
??? : No such
> file or directory."

You need to set up the LC_CTYPE environment variable. For example, if
you're from the US, you'll probably want to set it to "en_US.UTF-8".
This needs to be set before bash is invoked. There are at least two
ways to do this:

1) Add a line like this to the cygwin.bat script in your Cygwin
install directory:
set LC_CTYPE=3Den_US.UTF-8

2) Set the variable in the Windows environment, either by going to
Computer->Properties->Advanced->Environment Variables and addiing it
there, or by using the 'setx' command line tool that comes with the
Windows Resource Kit Tools (or preinstalled with some Windows
variants).

The second method is preferable if you want that variable to be set
when starting Cygwin programs without going through cygwin.bat.

Andy

--
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

