$Bill Luebkert wrote:

> Dan Jablonsky wrote:
> 
> 
>>Hi all,
>>I am trying to read only files in a directory; I need
>>to jump over the dot files and any subdirectories.
>>Seems like a simple thing, however with
>>
>>opendir(DIR, $dir) || die "can't opendir $dir: $!";
>>foreach my $file (readdir DIR) 
>>{
>>    next if (/^\./); # skip over dot files
> 
>       next if "$dir/$file" =~ (/^\./);

My bad - it should just be $file above and the below is correct.

> or just do them both with :
> 
>       next if -d "$dir/$file";
_______________________________________________
Perl-Win32-Users mailing list
Perl-Win32-Users@listserv.ActiveState.com
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs

Reply via email to