Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

list files in .zip on FTP ...

Status
Not open for further replies.

MoshiachNow

IS-IT--Management
Feb 6, 2002
1,851
IL
HI,

Is there some way to list a zip files on some FTP site to tell the files dates?

wget can do some things,and unzip can also do some,but is there some Perlish way to get these two to work together,or maybe some library that achieves the goal ?
thanks

Long live king Moshiach !
 
Code:
use LWP::Simple;
use Archive::Zip;

my $zip = get "ftp://site/zipfile.zip";
# or use Net::FTP if it requires authentication

# save it locally,
# open it with Archive::Zip,
# ???
# profit!

-------------
Cuvou.com | My personal homepage
Code:
perl -e '$|=$i=1;print" oo\n<|>\n_|_";x:sleep$|;print"\b",$i++%2?"/":"_";goto x;'
 
Have you seen an FTP client that can do this? I haven't (not even the Windows Explorer built-in FTP client, which logically should be able to open remote zip files, since Windows XP started calling them "compressed folders" that could be opened like normal folders), so I would guess it can't be done without downloading the file. If you have access to, you might have a script run on the remote server that lists all the files into a text file of the same name, and then just download and read the text file.

-------------
Cuvou.com | My personal homepage
Code:
perl -e '$|=$i=1;print" oo\n<|>\n_|_";x:sleep$|;print"\b",$i++%2?"/":"_";goto x;'
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top