| Path: | doc/GettingStarted.txt |
| Last Update: | Mon Dec 01 01:31:37 GMT+10:00 2003 |
This software is not supposed to be used by many people! It is used to generate HTML documentation and status reports. Wouldn‘t you rather download these or view them online rather than generate them yourself? If so, go to www.ruby-doc.org/stdlib/index.html.
You tell the software where to find the Ruby source code, and it has a list of packages in the standard library that it wants to document. It will run rdoc on each of these, collecting the results in a directory of your choice. It will also generate some ‘packaging’ files, like table of contents and overview.
The results of this can be seen at www.ruby-doc.org/stdlib/index.html.
The documentation that gets generated obviously doesn’t come from nowhere. rdoc collects comments from source code and turns it into cross-referenced documentation. Adding comments to Ruby’s standard library for this purpose is a volunteer effort. Now that we have a decent collection of documentation, it has become important to keep track of progress. Running a status report involves selecting a type of report, piping it through less, and squinting to make out the important information.
Mercifully, status reports are generated along with the documentation, so they can be examined more easily.
The software itself has an unavoidable dependency on ‘extensions’ (extensions.rubyforge.org). If you want to build tarballs, generate RDoc for the software, etc., you should have ‘rake’ (rake.rubyforge.org) as well.
You must edit etc/cfg/stdlib-doc.yaml in order to specify the Ruby base directory and the documentation output directory. It will guess where to put the generated documentation if necessary, but it can’t guess where your Ruby source base is located, and without knowing that, it can’t generate any documentation.
The default location for generated documentation is html. The default config file overrides this to stdlib for packaging purposes.
This project is designed to be run directly from its CVS checkout directory. It is not "installed", and it is not distributed (i.e. you must get it via CVS). The reason for this is that it is heavily dependent on its two databases, status.yaml and gendoc.yaml, and you need CVS to keep these up to date.
From the root directory, run:
$ ruby stdlib-doc.rb [message that tells you to specify status or gendoc] $ ruby stdlib-doc.rb status --help [help on getting status reports] $ ruby stdlib-doc.rb gendoc --help [help on generating documentation]
The help provided by the commands should be sufficient.
One way to generate all the documentation is this:
$ rake gendoc
In the root directory of the package, there are the following files and directories:
doc/ProgrammersGuide.txt contains the Programmers’ Guide, which explains the guts of this package so that you can understand how it works. You can read this as plain text, online at stdlib-doc.rubyforge.org, or in your own generated RDoc.