From: Lincoln Anderson Date: 2006-09-12T23:51:14+09:00 Subject: Re: Net::FTP questions... -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Vincent Arnoux wrote: > Hi, > > Le mardi 12 septembre 2006 à 07:39 +0900, Lincoln Anderson a écrit > : >> Here's where my problem comes in. How can I tell from the list >> array whether an item is a directory or a file to be copied? Is >> there something I can use (such as an FTP command) to catch a >> clue on how to implement this? I know this is possible, as >> ftpmirror is done with PERL and Ruby can do anything PERL can do >> - better :) > > The output of FTP#ls should be something like : drwxr-x--- 2 > login ftp 96 Sep 11 16:07 mydir -rwxr-x--- 2 login ftp > 96 Sep 11 16:07 myfile > > So you will know an entry is a directory if the string begins by > "d". > > Vincent > > > > > Yeah, I noticed that after my post... I guess I was trying to complicate things :) Thanks, Lincoln Anderson -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.2 (MingW32) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org iD8DBQFFBsk+Kte2c0P8BH0RAgagAJ99pzUNbgqd4Xla9/NYxXfCqt7ZJgCfc0qd oC7upPw6SIZTOEMr17A66FE= =hrJu -----END PGP SIGNATURE-----