Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 9 Apr 2017 06:26:09 +0300
From:      Andrey Chernov <ache@freebsd.org>
To:        =?UTF-8?Q?Nilton_Jos=c3=a9_Rizzo?= <rizzo@i805.com.br>, Toomas Soome <tsoome@me.com>
Cc:        Allan Jude <allanjude@freebsd.org>, FreeBSD Current <freebsd-current@freebsd.org>, owner-freebsd-current@freebsd.org
Subject:   Re: problem with ls, not show a correct list
Message-ID:  <f36a1aca-fcc0-1486-986a-279155a850f7@freebsd.org>
In-Reply-To: <1ba4fb7aa090271be631f01e9f72d844@i805.com.br>
References:  <fe2da09242ff63acb0c62dd0519cfa1f@i805.com.br> <25969d2c-6857-77a4-86a4-08b22f15cbfe@freebsd.org> <c0b1548a69d63a72ea73a299e55a0be9@i805.com.br> <7a08478e-ee7c-70f6-1b52-bb966f47c594@freebsd.org> <A332BA67-E71E-4CDF-AB98-241A802F8EFA@me.com> <1ba4fb7aa090271be631f01e9f72d844@i805.com.br>

next in thread | previous in thread | raw e-mail | index | archive | help
On 07.04.2017 23:20, Nilton José Rizzo wrote:
> Em 2017-04-07 05:51, Toomas Soome escreveu:
>>> On 7. apr 2017, at 11:29, Andrey Chernov <ache@freebsd.org> wrote:
>>>
>>>>  Hi Allan, the ls show all files without case match
>>>>
>>>> ls [a-z]*
>>>>
>>>> show all files beginning with a and A  like this [aA-zZ]*
>>>
>>> No, last "Z" is not included.
> 
> 
>    Look this, it's a great error!!!!

I see no error. You do not include Z into [a-z] expression above, so why
you expect it is unknown.

> I lower- equal a upper-case why Z not show in this list?

No, it is not case-equal sorting. As I already mention, it is
dictionaries sorting, letters considered first, their case - next (and
maybe many other factors for non-ASCII - next).

> image when a admin use like thinks some rm -rf /*/[A-Z]*

Admin should either run C or US-ASCII locale or do not use a-z ranges
without knowing sorting on his locale.

I see no errors in your sh examples.

In general it was decided (not by me) to use CLDR collation since it is
able to stable sort all Unicode chars.





Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?f36a1aca-fcc0-1486-986a-279155a850f7>