bug-findutils
[Top][All Lists]
Advanced

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

Bug in find's -regex switch?


From: Aleksander Adamowski
Subject: Bug in find's -regex switch?
Date: Tue, 22 Apr 2003 16:50:44 +0200
User-agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.3) Gecko/20030312

Hi!
I think I've found a bug in find's regex option. I'm using findutils-

I have the directory with a following subdirectory:

2003-04-22

When I launch "find ./" I get:

./
./2003-04-22

When I launch "find ./ -regex '.*[0-9]*-.*'" I get:

 ./2003-04-22

So far so good. When I launch "find ./ -regex '.*[0-9]{4}-.*'" I get empty results. Ok, maybe those are basic regular expressiona (as deatiled in regex in chapter 7 of manpages), and I need to escape boundary's curly braces: I try to launch "find ./ -regex '.*[0-9]\{4\}-.*'". I get empty results. I launch "find ./ -regex '.*[0-9]\{4,4\}-.*'". I get empty results. I launch "find ./ -regex '.*[0-9]{4,4}-.*'". I get empty results.

So it seems that the regex switch only implements some undocumented subset of regular expressions syntax.


--
Best Regards,
    Olo
        GG#: 274614
        ICQ UIN: 19780575
        http://olo.office.altkom.com.pl





reply via email to

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