--- trunk/run.pl 2009/04/25 14:46:42 1164 +++ trunk/run.pl 2009/05/18 18:47:22 1183 @@ -11,7 +11,7 @@ use WebPAC::Input 0.16; use WebPAC::Store 0.15; use WebPAC::Normalize 0.22; -use WebPAC::Output::TT; +#use WebPAC::Output::TT; use WebPAC::Validate 0.11; use WebPAC::Output::MARC; use WebPAC::Config; @@ -412,10 +412,18 @@ if ( $mirror ) { my $path = $input->{path} || die "no input path in ",dump( $input ); - $log->info( "mirror ", $path, " ", -s $path, " bytes" ); - $log->warn( "$path not modified" ) - if mirror( "$mirror/$path", $path ) == RC_NOT_MODIFIED; + my $base = $path; + $base =~ s{/[^/]+$}{}; + mkpath $base unless -e $base; + + my $rc = mirror( "$mirror/$path", $path ); + if (is_error( $rc )) { + die "can't mirror $mirror/$path -> $path [$rc]"; + } else { + $log->info( "mirror ", $path, " [$rc] ", -s $path, " bytes" ); + } + } my $input_db = new WebPAC::Input(