use File::Find::Rule; my $iter = rule( not => rule( directory => name => qr/dir(?:One|Two|Three)/, prune => ), start => '/your/path/here' ); while(my $thing = $iter->match) { ... }