bug-bash
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: nocaseglob


From: Tim Waugh
Subject: Re: nocaseglob
Date: Mon, 22 Jan 2007 16:24:35 +0000

On Mon, 2007-01-22 at 08:04 -0800, Bruce Korb wrote:
> There seems to be something else aside from LC_ALL, LC_COLLATE
> and LANG that affects collating sequence.  Notice the difference
> between "[a-d]*" and "[a-D]*".  Whatever collating sequence is being used
> do select files puts "D" after "d", though the actual sort puts them as being
> equal.  Whatever.  I've gotten bored now. :)

It's worth noting here that bash's globbing of '[A-Z]*' etc is
definitely different from the system collation sequence (i.e. using
fnmatch() or glob() functions).  There is an open bug report about this
here:

  https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=217359

Demo:

Steps to Reproduce:
1. touch h
2. sh -c 'LC_ALL=en_US; echo [A-Z]'
3. python -c 'from locale import *; import glob; setlocale(LC_ALL,"en_US");
print glob.glob("[A-Z]")'

Tim.
*/

Attachment: signature.asc
Description: This is a digitally signed message part


reply via email to

[Prev in Thread] Current Thread [Next in Thread]