Skip to content

Commit

Permalink
back to pandoc-ruby
Browse files Browse the repository at this point in the history
  • Loading branch information
Fuzzwah committed Feb 29, 2024
1 parent a080ef6 commit 1bc2ae2
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 8 deletions.
2 changes: 1 addition & 1 deletion Gemfile
Expand Up @@ -15,5 +15,5 @@ gem 'twitter-text', '~> 3.1'
gem "wikicloth", "= 0.8.3"
gem 'asciidoctor', '~> 2.0', '>= 2.0.21'
gem 'rake', '~> 13.1'
gem 'paru', '~> 1.2.0'
gem 'pandoc-ruby', '~> 2.1.10'

10 changes: 3 additions & 7 deletions lib/github/markups.rb
@@ -1,7 +1,7 @@
require "github/markup/markdown"
require "github/markup/rdoc"
require "shellwords"
require "paru/pandoc"
require 'pandoc-ruby'

markup_impl(::GitHub::Markups::MARKUP_MARKDOWN, ::GitHub::Markup::Markdown.new)

Expand Down Expand Up @@ -48,12 +48,8 @@
Asciidoctor.convert(content, :safe => :secure, :attributes => attributes)
end

markup(::GitHub::Markups::MARKUP_RST, :paru, /re?st(\.txt)?/, ["rst"]) do |filename, content, options: {}|
output = Paru::Pandoc.new do
from "rst"
to "html"
end << content
puts output
markup(::GitHub::Markups::MARKUP_RST, :pandoc-ruby, /re?st(\.txt)?/, ["reStructuredText"]) do |filename, content, options: {}|
PandocRuby.new(content, from: "rst").to_html
end

command(::GitHub::Markups::MARKUP_POD6, :pod62html, /pod6/, ["Pod 6"], "pod6")
Expand Down

0 comments on commit 1bc2ae2

Please sign in to comment.