Re: Ruby documentation (was Re: RUBY or (PHP5+PEAR+SMARTY))

On Jun 18, 2006, at 17:12, James B. wrote:

Please see http://ruby-doc.org/stdlib/status.html

This sounded interesting, so I dropped by, then started looking through
some of the files to see if I knew enough about Ruby to contribute.

Probably not yet. :slight_smile: However, I wanted to compare a “done” module with
one of the unfinished ones, so I opened up getoptlong.rb, which is
marked as “done” and has a score of 10.

I think I found some typos or glitches.

OK, so the first puzzle is that it isn’t in my “ri” doc directory at
all. Now, since I don’t like ri’s interface, I rebuilt all the docs, so
my HTML version DOES have RDoc output for GetoptLong.

First was this. Under the heading “Constants,” I see

ORDERINGS	=	[REQUIRE_ORDER = 0, PERMUTE = 1, RETURN_IN_ORDER = 2]
	Orderings.
ARGUMENT_FLAGS	=	[NO_ARGUMENT = 0, REQUIRED_ARGUMENT = 1,

OPTIONAL_ARGUMENT = 2]
Argument flags.
STATUS_TERMINATED = 0, 1, 2

It’s that last line that doesn’t make sense. The actual Ruby code looks
like

Orderings.

ORDERINGS = [REQUIRE_ORDER = 0, PERMUTE = 1, RETURN_IN_ORDER = 2]

Argument flags.

ARGUMENT_FLAGS = [NO_ARGUMENT = 0, REQUIRED_ARGUMENT = 1,
OPTIONAL_ARGUMENT = 2]

Status codes.

STATUS_YET, STATUS_STARTED, STATUS_TERMINATED = 0, 1, 2

Something about the status codes isn’t coming out through RDoc
correctly, I think.

The other item I spotted just looks like a simple typo.

Set/Unset `quit’ mode.

attr_writer :quiet

It seems likely to me that it should be “quiet” mode, not “quit” mode.
:slight_smile:

Where should I send such observations?

On Jun 19, 2006, at 11:47 PM, Dave H. wrote:

[snip: documentation corrections]
Where should I send such observations?

If you’re just sending observations, ruby-doc mailing list seems
good. If you make a patch, submit it to ruby-core mailing list.
http://ruby-doc.org/stdlib/status.html also says you can send it to
Gavin S., but I haven’t gotten any mail from him confirming this.

I’ve also been told to get set up with: http://stdlib-
doc.rubyforge.org/rdoc/index.html
It will generate documentation from bleeding edge cvs, so you can be
sure you’re not re-fixing things.

-Mat

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs