= RDOC - Ruby Documentation System

This package contains Rdoc and SimpleMarkup. Rdoc is an application
that produces documentation for one or more Ruby source files. We work
similarly to JavaDoc, parsing the source, and extracting the
definition for classes, modules, and methods (along with includes and
requires).  We associate with these optional documentation contained
in the immediately preceding comment block, and then render the result
using a pluggable output formatter. (Currently, HTML is the only
supported format. Markup is a library that converts plain text into
various output formats. The Markup library is used to interpret the
comment blocks that Rdoc uses to document methods, classes, and so on.


== Installation

This distribution contains two packages, rdoc itself and a text markup
library, 'markup'. You can install them both using the single command

  % ruby install.rb

in this directory. If you just want to install 'markup', change to the
markup directory and run the install.rb script there.


== Roadmap

* If you want to use Rdoc to create documentation for your Ruby source
  files, see rdoc/rdoc.rb.
* For information on the various markups available in comment
  blocks, see markup/simple_markup.rb.
* If you want to drive Rdoc programatically, see RDoc::RDoc.
* If you want to use the library to format text blocks into HTML,
  have a look at SM::SimpleMarkup.
* If you want to try writing your own HTML output template, see
  RDoc::Page.

== Summary

Once installed, you can create documentation using the 'rdoc' command
(the command is 'rdoc.rb' under Windows)

  % rdoc [options]  [names...]

Type "rdoc --help" for an up-to-date option summary.

A typical use might be to generate documentation for a package of Ruby
source (such as rdoc itself). 

  % rdoc

This command generates documentation for all the Ruby source files in
and below the current directory. These will be stored in a
documentation tree starting in the subdirectory 'doc'.

You can make this slightly more useful for your readers by having the
index page contain the documentation for the primary file. In our
case, we could type

  % rdoc --main rdoc/rdoc.rb

You'll find information on the various formatting tricks you can use
in comment blocks in the documentation this generates.


== Credits

* The Ruby parser in rdoc/parse.rb is based heavily on the outstanding
  work of Keiju ISHITSUKA of Nippon Rational Inc, who produced the Ruby
  parser for irb and the rtags package.

* Code to diagram classes and modules was written by Sergey A Yanovitsky
  (Jah) of Enticla. 

== License

RDoc is Copyright (c) 2002 Dave Thomas, The Pragmatic Programmers.  It
is free software, and may be redistributed under the terms specified
in the README file of the Ruby distribution.


== Support

The Rdoc homepage is http://rdoc.sourceforge.net. There you'll find
links for downloading the Rdoc package, and instructions on how to get
the still-quivering sources from CVS. I'm also using Sourceforge to
track bugs and manage feature requests. If you submit patches, it
would help if they were inline (not attachments) and generated using
"diff -u".  I don't have access to a wide variety of browsers, so
reports that output looks funny under Browser XYZ aren't too helpful:
far better are suggested changes to the generated HTML that fix the
problem.

For other information, feel free to ask on the ruby-talk mailing list
(which is mirrored to comp.lang.ruby) or contact
mailto:dave@pragmaticprogrammer.com.


== Warranty

This software is provided "as is" and without any express or
implied warranties, including, without limitation, the implied
warranties of merchantibility and fitness for a particular
purpose.


== Author

Dave Thomas, The Pragmatic Programmers.
Copyright (c) 2002, Dave Thomas

