if ($srch_file) { $LookFor .= "$^srch_file.*?"; } else { $LookFor .= '^[A-Za-z]+?'; } if ($srch_year) { $LookFor .= "\.$srch_year"; } else { $LookFor .= '\.\d+?'; } if ($srch_month) { $LookFor .= "\.$srch_month"; } else { $LookFor .= '\.\w+?'; } if ($srch_host) { $LookFor .= "\.$srch_host"; } else { $LookFor .= '\.\w+?'; } print "Looking in:\n"; #look in the specified dir paths set in the search_dirs foreach (@Search_Dirs) { print "\t$_/\n"; #print out dir paths that it searched } print "For file names matching: /$LookFor/\n"; #print out the file names that matches