From owner-freebsd-hackers@freebsd.org Wed Mar 8 15:59:58 2017 Return-Path: Delivered-To: freebsd-hackers@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id B93CED03C55 for ; Wed, 8 Mar 2017 15:59:58 +0000 (UTC) (envelope-from guru@unixarea.de) Received: from ms-10.1blu.de (ms-10.1blu.de [178.254.4.101]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 20DFE75D; Wed, 8 Mar 2017 15:59:58 +0000 (UTC) (envelope-from guru@unixarea.de) Received: from [88.217.107.178] (helo=localhost.unixarea.de) by ms-10.1blu.de with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.86_2) (envelope-from ) id 1cle0C-0006iX-MU; Wed, 08 Mar 2017 16:59:48 +0100 Received: from localhost.my.domain (c720-r292778-amd64 [127.0.0.1]) by localhost.unixarea.de (8.15.2/8.14.9) with ESMTPS id v28FxlvB004212 (version=TLSv1.2 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=NO); Wed, 8 Mar 2017 16:59:47 +0100 (CET) (envelope-from guru@unixarea.de) Received: (from guru@localhost) by localhost.my.domain (8.15.2/8.14.9/Submit) id v28Fxl53004211; Wed, 8 Mar 2017 16:59:47 +0100 (CET) (envelope-from guru@unixarea.de) X-Authentication-Warning: localhost.my.domain: guru set sender to guru@unixarea.de using -f Date: Wed, 8 Mar 2017 16:59:47 +0100 From: Matthias Apitz To: Xin Li Cc: Baptiste Daroussin , "freebsd-hackers@freebsd.org" , d@delphij.net, theraven@freebsd.org Subject: Re: Why en_US.UTF-8 locale consider a < A? Message-ID: <20170308155947.GA4129@c720-r292778-amd64> Reply-To: Matthias Apitz Mail-Followup-To: Matthias Apitz , Xin Li , Baptiste Daroussin , "freebsd-hackers@freebsd.org" , d@delphij.net, theraven@freebsd.org References: <062a0098-1975-6d2b-b017-f623e46ca20b@delphij.net> <20170308084047.qc2j3vnrh5hycg32@ivaldir.net> <7ad51573-c575-ad2f-b3bd-b011d15981ed@delphij.net> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <7ad51573-c575-ad2f-b3bd-b011d15981ed@delphij.net> X-Operating-System: FreeBSD 11.0-CURRENT r292778 (amd64) User-Agent: Mutt/1.5.24 (2015-08-30) X-Con-Id: 51246 X-Con-U: 0-guru X-Originating-IP: 88.217.107.178 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 08 Mar 2017 15:59:58 -0000 El día Wednesday, March 08, 2017 a las 12:51:11AM -0800, Xin Li escribió: > > > On 3/8/17 00:40, Baptiste Daroussin wrote: > >> Is this result correct? It matches some Debian behavior but not macOS > >> behavior. > > > > Yes the result is correct, macOS does not have unicode collation if you want to > > match the macos behaviour you have to set LC_COLLATE=C > > Thanks, I also found this https://www.cl.cam.ac.uk/~mgk25/unicode.html > just for the record if someone else hits the same issue. I recently came across with a related problem and have two questions (unresolved until now): 1. Using sort, reading the man page of it, it should be sufficient to set LC_COLLATE correctly. It seems that setting LANG (or unsetting it) changes the sort Order, why? 2. Speaking about German Umlauts, should they be treated as their normal letters, i.e. 'ä' is like 'a', as one can read in Wiki, or how they are sorted exactly? matthias -- Matthias Apitz, ✉ guru@unixarea.de, ⌂ http://www.unixarea.de/ ☎ +49-176-38902045