in reply to File searching
See. perlre for more info on the regex above.## is the .+ necessary after bb? if( $hit =~ /%(?:ff|jj|bb)/ ) ## alternate version if( $hit =~ /%[fjb]\1\b/ )
And being the local File::Find::Rule pimp I feel obliged to provide a code example
That should recursively find all files who's contents successfully match the regex in the /disk1/disk2 directory. See. File::Find::Rule for more info.use File::Find::Rule; my @files = find( file => grep => qr/%[fjb]\1\b/, in => '/disk1/disk2' );
_________
broquaint
update: fixed dodgy regex, thanks go to diotalevi
update 2: added a corrected version of the OP's regex
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Re: File searching
by diotalevi (Canon) on Jun 20, 2003 at 11:59 UTC | |
by Anonymous Monk on Jun 20, 2003 at 19:13 UTC | |
by diotalevi (Canon) on Jun 20, 2003 at 19:20 UTC | |
by Anonymous Monk on Jun 20, 2003 at 19:53 UTC | |
|
Re: Re: File searching
by zby (Vicar) on Jun 20, 2003 at 12:16 UTC |