Gentoo Archives: gentoo-user

From: Renat Golubchyk <ragermany@×××.net>
To: gentoo-user@l.g.o
Subject: Re: [gentoo-user] Bug in bash ?
Date: Sat, 21 Apr 2007 10:11:23
Message-Id: 20070421120455.1b7ebd06@mating-tux
In Reply to: Re: [gentoo-user] Bug in bash ? by Jan Seeger
1 On Sat, 21 Apr 2007 10:44:09 +0200 Jan Seeger <jan.seeger@×××××.com>
2 wrote:
3 > This is no bug. Bash globs everything that begins with A-Z (also
4 > directories) and then gives that list to ls. So ls lists all these
5 > files and the directories that begin with A-Z. Strangely though, bash
6 > seems to ignore case. (When I try your command, ls gives me all the
7 > files that begin with a letter and excludes files that begin with a
8 > number)
9
10 That happens because of your locale setting. If LC_COLLATE is not "C"
11 or "POSIX" then e.g. [A-D] can be equal to [AbBcCdD] or [AaBbCcD]. So
12 set LC_COLLATE to "C" and you'll get a "portable" behaviour.
13
14 Cheers,
15 Renat
16
17 --
18 Probleme kann man niemals mit derselben Denkweise loesen,
19 durch die sie entstanden sind.
20 (Einstein)

Attachments

File name MIME type
signature.asc application/pgp-signature