Sha256: a212463376f0a1e4d8b89644f3a04655bfb1f39e3f7a2370dc029ba86d760f08
Contents?: true
Size: 1018 Bytes
Versions: 36
Compression:
Stored size: 1018 Bytes
Contents
require "metanorma/processor" module Metanorma module Csd class Processor < Metanorma::Processor def initialize @short = :csd @input_format = :asciidoc @asciidoctor_backend = :csd end def output_formats super.merge( html: "html", pdf: "pdf", doc: "doc" ) end def version "Metanorma::Csd #{Metanorma::Csd::VERSION}" end def input_to_isodoc(file, filename) Metanorma::Input::Asciidoc.new.process(file, filename, @asciidoctor_backend) end def output(isodoc_node, outname, format, options={}) case format when :html IsoDoc::Csd::HtmlConvert.new(options).convert(outname, isodoc_node) when :doc IsoDoc::Csd::WordConvert.new(options).convert(outname, isodoc_node) when :pdf IsoDoc::Csd::PdfConvert.new(options).convert(outname, isodoc_node) else super end end end end end
Version data entries
36 entries across 36 versions & 1 rubygems