I find File::Find::Rule much easier to use that File::Find and for this case even has a grep method.
So you code to get the file-names containing your pattern(s) could look something like this (untested )
my @files = File::Find::Rule->file() ->name( '*.dpt' ) ->grep( $pattern ) ->in( $dir );
In reply to Re: Grep file out of directory and read into array
by RichardK
in thread Grep file out of directory and read into array
by Jalcock501
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |