Pandocr—Wrap Pandoc in Crystal

Pandorc is a Crystal wrapper around pandoc, the great multi-format converter.

License

Pandocr is free sofware; pandocr is released under the EUPLv1.2.

Installation and usage in your Crystal project

Add Pandocr to your shards.yml file:

# ...
dependencies:
  # ...
  pandocr:
    git: https://codeberg.org/CampineComputing/pandocr.git
    version: ~> 0.1.0
# ...    

Pandocr says "Hello, World!"

require "pandocr"

pandoc = Pandocr::Converter.new

pandoc.from = Pandocr::OptionType::FromFormat::Markdown
pandoc.to = Pandorc::OptionType::ToFormat::Html

greeting = pandoc.convert "Hello, *World*!"

puts greeting
# => <p>Hello, <em>World</em>!</p>

Documentation

Feel free to ask me a question. Send me an email or submit a new issue.