[Nitro] RDog ping

James Britt james.britt at gmail.com
Thu Jun 22 02:10:46 EDT 2006

Andrew Thompson wrote:

> Rdoc allows you to write new 'generators', it ships with 3; the xml the
> html and the ri ones, anyone can develop more but it's a real pain in
> the ass to do so.

One approach that has floated through my mind is writing an rdoc HTML 
template that emits Nitro XHTML, with each Nitro file representing a 
discrete Ruby source file.   Then load up all the files to create the 
in-memory object representation of the API data.

I'm not clear just how this would work, but I was struck by Nitro's 
bluring of XHTML files and Ruby source.  Something along the lines of 
imaging what if the various rdoc HTML pages were active objects that 
could exchange messages with each other.

Creating template to directly generate Ruby files might be useful, too. 
  In the end, what I looking for is a way to think about the API data as 
a set of related objects, and not as a particular database schema.

It's not that I'm so sure this is a good approach, more that it has an 
intrinsic, but ill-defined, appeal to me.

I've munged ruedoc  to emit a yaml file for each source file; then I 
wondered if I just recreated ri.   Maybe, though the resulting yaml 
seems a bit easier to play with.  A useful feature is that each yaml 
file knows where it came from, so any doc server that used it could 
pinpoint when a method was part of a mixin (such as yaml.rb) and not 
intrinsic to some core class.

James Britt

http://www.ruby-doc.org       - Ruby Help & Documentation
http://www.artima.com/rubycs/ - The Journal By & For Rubyists
http://www.rubystuff.com      - The Ruby Store for Ruby Stuff
http://www.30secondrule.com   - Building Better Tools

More information about the Nitro-general mailing list