When did linux become caseless?
mike chamberlain
mike.chamberlain at gmail.com
Fri Jun 15 11:23:21 BST 2007
On 6/15/07, Dirk Koopman <djk at tobit.co.uk> wrote:
> Subject says it all really. Just did "rm [A-Z]*" and had a load of files
> with lower case first letters removed as well. Same thing happens for
> "ls -d [A-Z]*"
>
It's locale dependant.
Try setting your locale to C.
bash-2.05$ cd foo
bash-2.05$ touch Foo
bash-2.05$ touch bar
bash-2.05$ ls -ald [A-Z]*
-rw-r--r-- 1 chambm02 staff 0 Jun 15 11:22 bar
-rw-r--r-- 1 chambm02 staff 0 Jun 15 11:22 Foo
bash-2.05$ export LC_ALL=C
bash-2.05$ ls -ald [A-Z]*
-rw-r--r-- 1 chambm02 staff 0 Jun 15 11:22 Foo
bash-2.05$
Mike.
More information about the london.pm
mailing list