Discount (For Ruby) Implementation of John Gruber's Markdown
C HTML Ruby Perl PowerShell
Latest commit 676a381 May 8, 2016 @davidfstr davidfstr 2.2.0.1 release
Permalink
Failed to load latest commit information.
bin add `rdiscount --help' usage message Apr 25, 2010
discount @ 070f3ec
ext Fix compilation on MSVC. Enable Ruby 2.3.0 in CI. May 8, 2016
lib 2.2.0.1 release May 8, 2016
man 1.6.5 release Jun 15, 2010
test Add regression test for #121. Feb 1, 2015
.gitignore gitignore: Remove reference to old Appveyor log file. Jul 20, 2015
.gitmodules Update build system to support Discount 2.0.7. Feb 18, 2013
.travis.yml [Travis] Also test on 2.3.0 Jan 31, 2016
BUILDING Migrate various features from configure flags to runtime flags. Apr 22, 2016
CHANGELOG.md 2.2.0.1 release May 8, 2016
COPYING Update license to 3-clause BSD to match Discount 2.1.6. (#64) May 29, 2013
README.markdown Update continuous integration status badges. Jul 20, 2015
Rakefile Use RbConfig instead of Config Jan 31, 2015
appveyor-build.ps1 Appveyor: Add instructions for how to Unblock the script. May 5, 2016
appveyor.yml Clarify that Appveyor on 32-bit Windows does not work. Jul 20, 2015
rdiscount.gemspec 2.2.0.1 release May 8, 2016

README.markdown

Discount Markdown Processor for Ruby

Build Status Build status

Discount is an implementation of John Gruber's Markdown markup language in C. It implements all of the language described in the markdown syntax document and passes the Markdown 1.0 test suite.

CODE: git clone git://github.com/davidfstr/rdiscount.git
HOME: http://dafoster.net/projects/rdiscount/
DOCS: http://rdoc.info/github/davidfstr/rdiscount/master/RDiscount
BUGS: http://github.com/davidfstr/rdiscount/issues

Discount was developed by David Loren Parsons. The Ruby extension is maintained by David Foster.

INSTALL, HACKING

New releases of RDiscount are published to RubyGems:

$ [sudo] gem install rdiscount

The RDiscount sources are available via Git:

$ git clone git://github.com/davidfstr/rdiscount.git
$ cd rdiscount
$ rake --tasks

See the file BUILDING for hacking instructions.

USAGE

RDiscount implements the basic protocol popularized by RedCloth and adopted by BlueCloth:

require 'rdiscount'
markdown = RDiscount.new("Hello World!")
puts markdown.to_html

Additional processing options can be turned on when creating the RDiscount object:

markdown = RDiscount.new("Hello World!", :smart, :filter_html)

Inject RDiscount into your BlueCloth-using code by replacing your bluecloth require statements with the following:

begin
  require 'rdiscount'
  BlueCloth = RDiscount
rescue LoadError
  require 'bluecloth'
end

COPYING

Discount is free software; it is released under a BSD-style license that allows you to do as you wish with it as long as you don't attempt to claim it as your own work. RDiscount adopts Discount's license verbatim. See the file COPYING for more information.