in reply to next if regex matches
Both of these should work:
update: I added the $ to your original regex to match the end of the line (or before newline at the end), as I am assuming that these are the extensions to the files and hence will only appear at the very end of the string (you don't want a file like foo.txt.tmp matching)next unless ($path =~ /\.(?:txt|log)$/); next if ( $path !~ /\.(?:txt|log)$/;
-enlil
|
|---|