Hi: If I am still using the below logic, how can i modify the below prog to ignore empty directories and list only directories containing directories and files in buildlist.txt ?
opendir DIR, $path or die "Can't open $path: $!";
#my @new = grep /[^.]/, readdir DIR;
my @new = grep { $_ ne "." and $_ ne ".." } readdir DIR;
closedir DIR;
open FILE,">>C:\buidlist.txt";
print FILE "$_\n" foreach @new;
close FILE;
