This is the mail archive of the
mailing list for the Cygwin project.
Re: UTF-8 compatibility between Windows and Cygwin
- From: Andrey Repin <anrdaemon at yandex dot ru>
- To: "Nellis, Kenneth" <Kenneth dot Nellis at conduent dot com>, cygwin at cygwin dot com
- Date: Thu, 25 May 2017 18:57:14 +0300
- Subject: Re: UTF-8 compatibility between Windows and Cygwin
- Authentication-results: sourceware.org; auth=none
- Authentication-results: smtp2m.mail.yandex.net; dkim=pass firstname.lastname@example.org
- References: <BN6PR2001MB1074BB00C47B3FD0DD0905F7F1FF0@BN6PR2001MB1074.namprd20.prod.outlook.com>
- Reply-to: cygwin at cygwin dot com
Greetings, Nellis, Kenneth!
> I have (BOM-less) UTF-8 text files that I can read fine in
> Cygwin, but not Windows. When I create text files in Windows
> containing non-ASCII characters, I cannot read them in
> Cygwin. I understand why, but wondering the best way to be
> able to share text files across the two environments.
Please provide `od -t x1z` of the file you are referring to.
> I'm pretty sure that I want to keep my Cygwin LANG=C.UTF-8
Better use real language indication, and configure LC_ according to
> but wondering what I can do on the Windows side for
> compatibility and what are the side effects.
On Windows side, you could actually use UTF-8.
Without seeing the requested dump, I can only guess, though.
> Windows's Command Prompt command chcp shows "Active code
> page: 437". (Is that obsolete or even relevant?)
Neither of the two, unless you consider relevance to the correct display of
the results and other console-related operations.
If you're often find yourself in a native console, I suggest you tweak LANG to
match (i.e. LANG=ru_RU.CP866 for me) and only change it to .UTF-8 for MinTTY
(it can help you with override, if you don't want to tweak your startup files).
> One solution seems to be to put a BOM in each UTF-8 text
> file; then the files read fine in both environments, but
> that's not conveniently accomplished.
That's hardly a solution, though. More like a workaround.
With best regards,
Thursday, May 25, 2017 18:48:43
Sorry for my terrible english...
Problem reports: http://cygwin.com/problems.html
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple