Skip to content

Commit

Permalink
Work around RDiscount bug where Markdown after Pygments-highlighted c…
Browse files Browse the repository at this point in the history
…ode would not be parsed as Markdown.

See http://gist.github.com/97682 for a runnable example of the bug.
  • Loading branch information
henrik committed Apr 18, 2009
1 parent 1a3a581 commit 60683ea
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion lib/jekyll/albino.rb
Expand Up @@ -71,7 +71,9 @@ def execute(command)
end

def colorize(options = {})
execute @@bin + convert_options(options)
html = execute(@@bin + convert_options(options))
# Work around an RDiscount bug: http://gist.github.com/97682
html.to_s.sub(%r{</pre></div>\Z}, "</pre>\n</div>")
end
alias_method :to_s, :colorize

Expand Down

0 comments on commit 60683ea

Please sign in to comment.