in reply to Execute a for loop in many subdirectories
while (defined(my $subdir = glob 'antarctica/*')) { next unless -d $subdir; chdir $subdir; for ... chdir '../..'; }
opendir my $D, 'antarctica' or die $!; while (defined(my $dir = readdir $D)) { $dir = "antarctica/$dir"; next unless -d $dir; chdir $dir; for ... chdir '..';
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: Execute a for loop in many subdirectories
by marlowvoltron (Novice) on May 22, 2014 at 20:32 UTC | |
by choroba (Cardinal) on May 22, 2014 at 21:06 UTC |