Skip to content

metanorma/mnconvert-ruby

Repository files navigation

mnconvert Ruby gem

Gem Version Ubuntu Build Status Code Climate Pull Requests Commits since latest

Purpose

The mnconvert Ruby gem is a wrapper around the Java mnconvert which:

  • converts Metanorma presentational XML into various output formats, including ISOSTS;

  • converts other formats to Metanorma AsciiDoc or Metanorma XML.

This gem is used to provide mnconvert.jar with mirrored version numbers, to allow Ruby code to easily refer to the desired mnconvert version as dependencies.

Installation

gem install mnconvert

Or include it in your gemspec.

Usage

require 'mnconvert'
MnConvert.convert(sample_xml_path, output_pdf_path)

Updating the gem

Update lib/mnconvert/version.rb to the desired version of mnconvert.

Run rake to download the bin/mnconvert.jar file:

rm -f bin/mnconvert.jar
rake bin/mnconvert.jar

Then release the gem with rake release.