Hi Kobby,

The first is fairly straightforward:

        @files = grep -d, <$your_filespec> ;

The  second requires a module:

        use File::Path ;
        rmtree $your_dir ;

hth,

Craig Arnold

-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
Sent: Thursday, September 26, 2002 8:33 AM
To: [EMAIL PROTECTED]
Subject: [Perl-unix-users] List of directories in a directory


How do I get a list of directories within a directory into an array ?

Can I remove directories containing files in perl ?

Thanks
Kobby





_____________________________________________________

This transmission has been issued by a member of the HSBC Group 
"HSBC" for the information of the addressee only and should not be 
reproduced and / or distributed to any other person. Each page attached 
hereto must be read in conjunction with any disclaimer which forms part 
of it. Unless otherwise stated, this transmission is neither an offer nor
the 
solicitation of an offer to sell or purchase any investment. Its contents
are 
based on information obtained from sources believed to be reliable but
HSBC makes no representation and accepts no responsibility or liability as 
to its completeness or accuracy.

_______________________________________________
Perl-Unix-Users mailing list
[EMAIL PROTECTED]
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs
_______________________________________________
Perl-Unix-Users mailing list
[EMAIL PROTECTED]
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs

Reply via email to