App-Basis-ConvertText2
view release on metacpan or search on metacpan
lib/App/Basis/ConvertText2.pm view on Meta::CPAN
my $outfile = $cf;
$outfile =~ s/\.html$/.$format/i;
# if the marked-up file is more recent than the converted one
# then we need to convert it again
if ( $format !~ /html/i ) {
# as we can generate PDF using a number of convertors we should
# always regenerate PDF output incase the convertor used is different
if ( !-f $outfile || $format =~ /pdf/i || ( ( stat($cf) )[9] > ( stat($outfile) )[9] ) ) {
$outfile = $self->_convert_file( $cf, $format, $pdfconvertor );
# if we failed to convert, then clear the filename
if ( !$outfile || !-f $outfile ) {
$outfile = undef;
debug( "ERROR", "failed to create output file from cached file $cf" );
}
}
}
( run in 0.855 second using v1.01-cache-2.11-cpan-49f99fa48dc )