Hi,
I need to pull a file or files down every day that contain a specific
string.   Here's my code.


#!/usr/bin/perl
use strict;
use Net::SCP;

my $scp=' ';
open (LOG, ">>/home/wesaysopost/logs/retrieve-wesayso-results.log") or die
"Can't open logfile";
LOG-> autoflush(1);

print LOG "Starting Retrieval Process";
$scp = Net::SCP->new ( "theserver.wesayso.com", "mylogin");
$scp->cwd("postingscript")  or die "Can't change directories";
$scp->get ("acme_posting*") or die "Can't retrieve results";
close LOG;
exit;

The file I'm retrieving is acme_posting20110415.txt   (date changes every
day)

The file is found, but it's being saved as acme_posting*

I'm not specifying a local file name when I get the file, why is SCP saving
it under a different name?

Thanks in Advance!

Dave

Reply via email to