bin/commonmarker in commonmarker-0.1.3 vs bin/commonmarker in commonmarker-0.2.0
- old
+ new
@@ -9,10 +9,11 @@
puts line[2..-1]
end
exit 0
end
+$LOAD_PATH.unshift File.join(File.dirname(__FILE__), *%w( .. lib ))
require 'commonmarker'
if ARGV.include?('--version') or ARGV.include?('-v')
puts "commonmarker #{CommonMarker::VERSION}"
exit 0
@@ -29,10 +30,10 @@
else
false
end
end
-doc = CommonMarker::Node.parse_file(ARGF)
+doc = CommonMarker.render_doc(ARGF.read)
if renderer
STDOUT.write(renderer.render(doc))
else
STDOUT.write(doc.to_html)