From: Ross Bamford Date: 2006-01-12T01:18:05+09:00 Subject: Re: rubygem, rdoc, ri, ... On Wed, 11 Jan 2006 15:27:46 -0000, mr ra88it wrote: >> > Ok, also, how do I access the doc of the ruby gems using ri or >> > rbbr ? I >> > saw nothing that would allow me to do so :S >> >> You don't. This is not a capability of ri. > > I love using ri to browse documentation and I'm amazed that it is not > capable of showing the documentation for ruby gems. Does anybody have > a good idea for how this might be achieved? If you really don't care about having the RDoc available via gem_server, then you could do something like the following. I'll assume here that gems are installed as root, for use sitewide. Just create a file, /root/.gemrc , with the following: rdoc: --ri-site Now run an install for a gem that you know has rdoc: su -c 'gem install cmdparse' Doesn't matter if it's already installed. Now check it's worked and is available to all users: ri CmdParse::CommandParser (substitute another if you have cmdparse ri already installed :)) As I say though doing this you'll lose the RDoc you get in gem_server I guess, but you should get RI on tap for your gems. Very nice from Eclipse. As a footnote, check out http://docs.rubygems.org/read/chapter/11#page55 for more information. You could do this on a per-gem basis, for example, by having a special config file you supply when needed, and it can be tailored to per-user gem install or whatever too I think. Cheers, -- Ross Bamford - rosco@roscopeco.remove.co.uk