Documentation for Ruby and Gems?

1 view
Skip to first unread message

cootcraig

unread,
Sep 10, 2010, 2:59:12 PM9/10/10
to Not Just Ruby
Please advise. How does a Ruby developer view documentation?

For instance I do
gem install prawn
and see:

Successfully installed prawn-core-0.8.4
Successfully installed prawn-layout-0.8.4
Successfully installed prawn-security-0.8.4
Successfully installed prawn-0.8.4
4 gems installed
Installing ri documentation for prawn-core-0.8.4...
Installing ri documentation for prawn-layout-0.8.4...
Installing ri documentation for prawn-security-0.8.4...
Installing ri documentation for prawn-0.8.4...
Installing RDoc documentation for prawn-core-0.8.4...
Installing RDoc documentation for prawn-layout-0.8.4...
Installing RDoc documentation for prawn-security-0.8.4...
Installing RDoc documentation for prawn-0.8.4...

Then I run
$ ri -l |grep -i prawn |less

Prawn
Prawn#PdfObject
Prawn#EncryptedPdfObject
Prawn::LiteralString
Prawn::OutlineItem
Prawn::Font
Prawn::Font::load
Prawn::Font#line_gap
Prawn::Font#normalize_encoding!
Prawn::Font#ascender
Prawn::Font#add_to_current_page
Prawn::Font#descender
Prawn::Font#height_at
Prawn::Font#height
Prawn::Font#normalize_encoding
Prawn::Font::DFont
Prawn::Font::DFont::font_count
Prawn::Font::DFont::named_fonts
...

I was expecting some kind of GUI for navigating,viewing,search the
local and web based docs.


FWIW. My environment is Ubuntu 10.04, using Bluefish as my project
editor.

Kevin McFadden

unread,
Sep 10, 2010, 3:18:52 PM9/10/10
to Not Just Ruby
Brooke mentioned the gem "open_gem".

There's also:

http://www.gotapi.com/rubyrails
http://apidock.com/rails

or you can just run "gem server" to see all the compiled documentation
for your installed gems right in your browser.

Kev

cootcraig

unread,
Sep 10, 2010, 7:09:32 PM9/10/10
to Not Just Ruby

"gem server" is very useful, I didn't know about this.
Reply all
Reply to author
Forward
0 new messages