all repos — markup @ 9dd2a32a2cabbc9083c0c646373cd0663981c451

The code we use to render README.your_favorite_markup

lib/github/markups.rb (view raw)

 1markup(:markdown, /md|mkdn?|markdown/) do |content|
 2  Markdown.new(content).to_html
 3end
 4
 5markup(:redcloth, /textile/) do |content|
 6  RedCloth.new(content).to_html
 7end
 8
 9markup('github/markup/rdoc', /rdoc/) do |content|
10  GitHub::Markup::RDoc.new(content).to_html
11end
12
13command(:rest2html, /rest|rst/)
14
15command(:asciidoc2html, /asciidoc/)
16
17command("/usr/bin/env pod2html", /pod/) do |rendered|
18  if rendered =~ /<!-- INDEX BEGIN -->\s*(.+)\s*<!-- INDEX END -->/mi
19    $1
20  end
21end