On 11/12/16 05:13, Peng Yu wrote:
> On mac, all the following LC_ALL result in the same results of sort.
> 
> 
> LC_ALL=en_US.UTF-8 sort <<< $'a\nb\nA\nB'
> A
> B
> a
> b
> LC_ALL=en_US sort <<< $'a\nb\nA\nB'
> A
> B
> a
> b
> LC_ALL=C sort <<< $'a\nb\nA\nB'
> A
> B
> a
> b
> 
> But they are not all the same on linux. Do anybody know a LC_ALL on
> mac that would make sort sort differently? Thanks.
> 
> LC_ALL=en_US.UTF-8 sort <<< $'a\nb\nA\nB'
> a
> A
> b
> B
> LC_ALL=en_US sort <<< $'a\nb\nA\nB'
> A
> B
> a
> b

I get en_US = en_US.UTF-8 on Linux as expected

> LC_ALL=C sort <<< $'a\nb\nA\nB'
> A
> B
> a
> b
> 

As to your question of getting a case insensitive collating order on osx, see:
http://apple.stackexchange.com/a/157906/62853

cheers,
Pádraig

Reply via email to