Skip to content

Commit

Permalink
Switch from Maruku to Redcarpet
Browse files Browse the repository at this point in the history
* Rename helper method to avoid naming collision.

Signed-off-by: Alex Coles <alex@alexbcoles.com>
  • Loading branch information
myabc committed Jul 16, 2012
1 parent 3e647cc commit 48cad19
Show file tree
Hide file tree
Showing 5 changed files with 17 additions and 4 deletions.
2 changes: 2 additions & 0 deletions Gemfile
Expand Up @@ -13,6 +13,8 @@ gem 'sitemap_generator'
gem 'coffee-script'
gem 'bourbon'
gem 'nokogiri'
gem 'redcarpet'
gem 'pygments.rb'

gem 'html5-boilerplate', :require => 'html5-boilerplate',
:git => 'git://github.com/edenspiekermann/compass-html5-boilerplate.git',
Expand Down
9 changes: 9 additions & 0 deletions Gemfile.lock
Expand Up @@ -59,6 +59,7 @@ GEM
i18n (~> 0.6)
multi_json (~> 1.0)
addressable (2.2.8)
blankslate (2.1.2.4)
bourbon (2.1.1)
sass (>= 3.1)
builder (3.0.0)
Expand Down Expand Up @@ -120,6 +121,8 @@ GEM
padrino-helpers (0.10.7)
i18n (~> 0.6)
padrino-core (= 0.10.7)
pygments.rb (0.2.13)
rubypython (~> 0.5.3)
rack (1.4.1)
rack-contrib (1.1.0)
rack (>= 0.9.1)
Expand All @@ -134,8 +137,12 @@ GEM
rb-fsevent (0.9.1)
rb-inotify (0.8.8)
ffi (>= 0.5.0)
redcarpet (2.1.1)
rest-client (1.6.7)
mime-types (>= 1.16)
rubypython (0.5.3)
blankslate (>= 2.1.2.3)
ffi (~> 1.0.7)
rubyzip (0.9.9)
sinatra (1.3.2)
rack (~> 1.3, >= 1.3.6)
Expand Down Expand Up @@ -173,8 +180,10 @@ DEPENDENCIES
middleman!
middleman-blog!
nokogiri
pygments.rb
rack-contrib
rack-rewrite
rake (~> 0.9.2)
redcarpet
sass!
sitemap_generator
2 changes: 2 additions & 0 deletions config.rb
Expand Up @@ -4,6 +4,8 @@
require 'active_support/core_ext/string'
require 'app/helpers/html5_boilerplate_helper'

set :markdown_engine, :redcarpet

###
# Blog settings
###
Expand Down
4 changes: 2 additions & 2 deletions lib/custom_tag_helpers.rb
Expand Up @@ -15,8 +15,8 @@ def to_s

module CustomTagHelpers

def md(text)
Maruku.new(text).to_html
def md2html(text)
Redcarpet::Markdown.new(Redcarpet::Render::HTML).render(text)
end

def wrapped(el = :div, attrs = {}, &block)
Expand Down
4 changes: 2 additions & 2 deletions source/speakers.html.haml
Expand Up @@ -14,7 +14,7 @@ body_class: speakers
%h3= link_to speaker.name, speaker.url
%div= link_to speaker.company, speaker.company_url
%div= link_to "@#{speaker.twitter}", "http://twitter.com/#{speaker.twitter}"
%p= md speaker.bio
%p= md2html speaker.bio

%h4 #{speaker.talk_title}
%p= md speaker.talk_summary
%p= md2html speaker.talk_summary

0 comments on commit 48cad19

Please sign in to comment.