Permalink
Browse files

Work around RDiscount bug where Markdown after Pygments-highlighted c…

…ode would not be parsed as Markdown.

See http://gist.github.com/97682 for a runnable example of the bug.
  • Loading branch information...
1 parent 1a3a581 commit 60683ea48b5616a5845c9d58f59555e7ac4779ba @henrik henrik committed Apr 18, 2009
Showing with 3 additions and 1 deletion.
  1. +3 −1 lib/jekyll/albino.rb
View
@@ -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

0 comments on commit 60683ea

Please sign in to comment.