delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2016/09/30/22:14:27

X-Recipient: archive-cygwin AT delorie DOT 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:message-id:to:subject:mime-version
:content-type:content-transfer-encoding; q=dns; s=default; b=cvi
Rc1vfD8qhHu7fQJ9xNtGniE5duDCghMR7Mo1QQOIiCvgDwR7IIqe65SyPzyyYSgC
gvMXDWTl2Xz1/fEL4hTJfKTz7XJcrS6rFxVR4mZARkulCbWKjTRK2NQ78z83UzWt
CjsgYGn3xab1Z8G2hMqqdV9+qdNNLo+8JsEyzXHw=
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:message-id:to:subject:mime-version
:content-type:content-transfer-encoding; s=default; bh=V1uhlG3wY
kmM2QZD4WPnzhTjSIE=; b=IYsyPg+/kiSyUAJbk/aY/YIG+7rXHgHxpSaqeAgRq
9TQlJJBDQoUGZiWzM0C1JymJPuwPggeolKRiQtGUj60zwXRudfQdrQNJecSW1a4z
+ERFXT7pcKbSf4nfiaBNGW9snWwx+QltAO2+r6Ti1fGHMzePtieoke21rmehJqFJ
6w=
Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Id: <cygwin.cygwin.com>
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com
Authentication-Results: sourceware.org; auth=none
X-Virus-Found: No
X-Spam-SWARE-Status: No, score=4.1 required=5.0 tests=AWL,BAYES_00,BODY_8BITS,GARBLED_BODY,LIKELY_SPAM_SUBJECT,SPF_PASS autolearn=no version=3.3.2 spammy=Manager, 8000
X-HELO: Marvin.c0d.org
Authentication-Results: marvin.c0d.org (amavisd-new); dkim=pass (1024-bit key) reason="pass (just generated, assumed good)" header.d=vanav.org
Date: Sat, 1 Oct 2016 05:13:47 +0300
From: Ivan Vanyushkin <vanav AT vanav DOT org>
Message-ID: <123291584.20161001051347@vanav.org>
To: cygwin AT cygwin DOT com
Subject: Cygwin 2.6.0: unreadable UTF-8 in Windows console
MIME-Version: 1.0
X-IsSubscribed: yes
Note-from-DJ: This may be spam

Something has changed in version 2.6.0, and now UTF-8 text can't be displayed in Windows console (cmd).

1. Create a file "test.txt" with non-ASCII text in UTF-8 encoding.
2. Run "cmd".
3. Run:

C:\Cygwin\bin\cat test.txt
â–’â–’â–’â–’â–’â–’â–’â–’â–’â–’â–’â–’â–’â–’â–’â–’ â–’â–’â–’â–’â–’â–’â–’â–’â–’â–’â–’â–’â–’â–’ â–’â–’â–’â–’ â–’â–’â–’â–’â–’â–’ 8000 â–’â–’. â–’â–’â–’â–’ â–’â–’â–’â–’â–’â–’â–’â–’â–’â–’â–’â–’â–’â–’â–’â–’â–’â–’â–’â–’â–’â–’ â–’â–’â–’â–’â–’â–’â–’â–’â–’â–’.

Non-ASCII text is not readable. Older Cygwin 2.5.2 has no such issue.

C:\Cygwin\bin\uname -a
CYGWIN_NT-10.0 PCName 2.6.0(0.304/5/3) 2016-08-31 14:32 x86_64 Cygwin

C:\Cygwin\bin\locale
LANG=
LC_CTYPE="C.UTF-8"
LC_NUMERIC="C.UTF-8"
LC_TIME="C.UTF-8"
LC_COLLATE="C.UTF-8"
LC_MONETARY="C.UTF-8"
LC_MESSAGES="C.UTF-8"
LC_ALL=

Same issue with any other commands like "grep", or with utilities built and run under Cygwin 2.6.0.
Same issue in other Windows consoles, like ConEmu or FAR Manager.
If I change Windows console encoding to UTF-8 (run: "chcp 65001"), file can be correctly displayed natively
(run: "type test.txt"), but Cygwin "cat" still has the same issue.

How should I display UTF-8 now?

Thank you.


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

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019