mirror of
https://github.com/jekyll/jekyll.git
synced 2026-01-31 01:38:24 -05:00
Render highlighted code for non markdown/textile pages. Fixes #116
This commit is contained in:
@@ -1,3 +1,7 @@
|
||||
== Edge
|
||||
* Bug Fixes
|
||||
* Render highlighted code for non markdown/textile pages (#116)
|
||||
|
||||
== 0.5.7 / 2010-01-12
|
||||
* Minor Enhancements
|
||||
* Allow overriding of post date in the front matter (#62, #38)
|
||||
|
||||
@@ -31,10 +31,10 @@ module Jekyll
|
||||
|
||||
def render_pygments(context, code)
|
||||
output = add_code_tags(Albino.new(code, @lang).to_s(@options), @lang)
|
||||
if context["content_type"] == "markdown"
|
||||
return "\n" + output + "\n"
|
||||
elsif context["content_type"] == "textile"
|
||||
return "<notextile>" + output + "</notextile>"
|
||||
case context["content_type"]
|
||||
when "markdown" then "\n" + output + "\n"
|
||||
when "textile" then "<notextile>" + output + "</notextile>"
|
||||
else output
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
Reference in New Issue
Block a user