all repos — markup @ 9359dbfe77392aeb8b08f6d0a4c4128b15c4ffe3

The code we use to render README.your_favorite_markup

use Pod::Simple::HTML to live in this century
Ricardo Signes rjbs@cpan.org
Wed, 03 Feb 2010 05:03:19 +0800
commit

9359dbfe77392aeb8b08f6d0a4c4128b15c4ffe3

parent

38cc6c487a9be468d392388d18bbe51b19bbb760

1 files changed, 3 insertions(+), 6 deletions(-)

jump to
M lib/github/markups.rblib/github/markups.rb

@@ -23,11 +23,8 @@ # so we return the favor by ripping out the good parts.

# # Any block passed to `command` will be handed the command's STDOUT for # post processing. -command("/usr/bin/env pod2html", /pod/) do |rendered| - require 'fileutils' - if rendered =~ /<body.+?>\s*(.+)\s*<\/body>/mi - FileUtils.rm("pod2htmd.tmp") if File.exists?('pod2htmd.tmp') rescue nil - FileUtils.rm("pod2htmi.tmp") if File.exists?('pod2htmi.tmp') rescue nil - $1.sub('<!-- INDEX BEGIN -->', '').sub('<!-- INDEX END -->', '') +command("/usr/bin/env perl -MPod::Simple::HTML -e Pod::Simple::HTML::go", /pod/) do |rendered| + if rendered =~ /<!-- start doc -->\s*(.+)\s*<!-- end doc -->/mi + $1 end end