in reply to Re^2: NET::FTP::Recursive
in thread NET::FTP::Recursive

So if I try the following ( $yesterdays_date(variable) being a directory inside the remote_path) is correct? I don't wish to remove the files just copy...
my $output = $ftp->rget([ParseSub =>\&$yesterdays_date]);

Replies are listed 'Best First'.
Re^4: NET::FTP::Recursive
by kwaping (Priest) on Jan 24, 2006 at 16:53 UTC
    If you're using version 1.6 or higher of Net::FTP::Recursive, this might better suit your needs:
    my $regex = qr/$yesterdays_date/; my $output = $ftp->rget(MatchDirs => $regex);
Re^4: NET::FTP::Recursive
by kwaping (Priest) on Jan 24, 2006 at 16:47 UTC
    Upon further inspection of the documentation, it appears the module's author forgot or otherwise neglected to document the usage of ParseSub.

    My guess is to do something like this:
    my $sub = sub { return shift =~ /$yesterdays_date/ }; my $output = $ftp->rget(ParseSub => $sub);
      I implemented your suggestion and the $sub call comes back undefined. The $yesterday_date is a date ...> 20060122.