Skip to content

Commit

Permalink
changed to be CLI distiller compliant
Browse files Browse the repository at this point in the history
  • Loading branch information
markwilkinson committed Jul 5, 2019
1 parent 204ca6b commit 29ec4c8
Showing 1 changed file with 3 additions and 2 deletions.
Expand Up @@ -414,8 +414,9 @@ def Utils::do_distiller(meta, body)
file.binmode
file.write(body)
file.rewind
meta.comments << "INFO: The message body is being examined by Apache Tika\n"
meta.comments << "INFO: The message body is being examined by Distiller\n"
result = %x{rdf serialize --input-format rdfa --output-format turtle #{file.path}}
$stderr.puts "RESULT #{result}\n\n\n"
file.close
file.unlink

Expand All @@ -425,7 +426,7 @@ def Utils::do_distiller(meta, body)
meta.comments << "WARN: The Distiller tool failed to find parseable data in the body.\n"
else
meta.comments << "INFO: The Distiller found parseable data. Parsing as RDF\n"
Utils::parse_rdf(meta, body, "text/turtle")
Utils::parse_rdf(meta, result, "text/turtle")
end

end
Expand Down

0 comments on commit 29ec4c8

Please sign in to comment.