[ANN] RedCloth 0.41 -- Textile for Ruby

h1. RedCloth

h2. Humane text for Ruby

RedCloth is a module for using Textile in Ruby. Textile is a text format. A
very simple text format. Someone’s stab at making readable text that can be
converted to HTML. See “here”:http://www.textism.com/tools/textile/.

h2. Installing RedCloth

In an hour or so, you should be able to install RedCloth via raa-install:

  raa-install -i redcloth

Or “download
RedCloth”:http://prdownloads.sourceforge.net/yaml4r/redcloth-0.41.tar.gz and
simply run the install.rb like so:

  ruby install.rb config
  ruby install.rb setup
  sudo ruby install.rb install

h2. Using RedCloth

The RedCloth class is an extension of Ruby’s String class. Use it like you
would a String:

  >> r = RedCloth.new "*strong text* and _emphasized text_"
  => "*strong text* and _emphasized text_"
  >> r.gsub!( 'text', 'words' )
  => "*strong words* and _emphasized words_"

To generate HTML from your RedCloth object, use the @RedCloth#to_html@ method:

  >> r.to_html
  => "

strong words and emphasized words

"

h2. The Textile language

See the “Textile home page”:http://www.textism.com/tools/textile/ for details
on the Textile language.