whoops has asked for the wisdom of the Perl Monks concerning the following question:

Hello all, I am really at a loss with this one.

I have a list of items that have corresponding pictures on a server and i need to be able to download only the pictures that correspond to items on my list. Example...

Item: M151 Picture name on server: Aficionado_M151_PHOTO1.jpg

I have my list of items (about 200) in an excel file.

I have tried using grep to find the files on the server, ive used ls() to get the list of all files, and many other things... Obviously i am missing something.

I am relatively new to perl and programming in general so any insight is appreciated. I would post my code but im hoping somebody can take it in a completely different that ive tried.

Thank you.

  • Comment on Retrieving a list of Specific Files from FTP

Replies are listed 'Best First'.
Re: Retrieving a list of Specific Files from FTP
by runrig (Abbot) on Sep 05, 2013 at 00:11 UTC
    Item: M151 Picture name on server: Aficionado_M151_PHOTO1.jpg
    Are you using Net::FTP?
      Yes i am.
        Then use ls() to list the files and get() to download them...or if you already have a list of files to get, then just get() them...and as far as grep goes, are you referring to command line grep, or perl grep? You really don't need to use the command line grep...I can see maybe using grep though...

        You may have to show some minimum amount of code to show what you're having trouble with.