From 3c39612d8488a7c4893226f94e34599d6cbdc715 Mon Sep 17 00:00:00 2001 From: Henrik N Date: Sat, 18 Apr 2009 21:56:15 +0200 Subject: [PATCH] Work around RDiscount bug where Markdown after Pygments-highlighted code would not be parsed as Markdown. See http://gist.github.com/97682 for a runnable example of the bug. Signed-off-by: Nick Quaranto --- lib/jekyll/albino.rb | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/lib/jekyll/albino.rb b/lib/jekyll/albino.rb index 1f6951d0..2497cb6d 100644 --- a/lib/jekyll/albino.rb +++ b/lib/jekyll/albino.rb @@ -71,7 +71,9 @@ class Albino 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{\Z}, "\n") end alias_method :to_s, :colorize