innuendo98 has asked for the wisdom of the Perl Monks concerning the following question:
$ftp = Net::FTP::Recursive->new($config{'host'}, isSymlink => 1, Debug + => 1); $ftp->login( $config{'user'}, $config{'pass'}); $ftp->cwd( $config{'trgt'}); my @listClients = $ftp->dir(); foreach $x (@listClients){ if (-l $x){ print "Inside link test ".$x."\n"; if (defined($clientLink = readlink($ftp->pwd()."/".$x))) { print "\t\t".$clientLink."\n"; $ftp-> cwd( $clientLink ); print $ftp->pwd(); } } else { $ftp->cwd( $client ); } } $ftp->binary(); $ftp->rput(); $ftp->quit;
2006-07-18 Retitled by Corion, as per Monastery guidelines
Original title: 'net::ftp'
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: transfering symlinks with Net::FTP
by sgifford (Prior) on Jul 18, 2006 at 03:16 UTC |