[lnkForumImage]
TotalShareware - Download Free Software

Confronta i prezzi di migliaia di prodotti.
Asp Forum
 Home | Login | Register | Search 


 

Forums >

comp.lang.ruby

ri in irb

Brian Buckley

4/27/2005 1:06:00 PM

Hello all,

From p.191 of the pickaxe2 book, I put the following into my irb.rc file.

def ri(*names)
system(%{ri #{names.map {|name| name.to_s}.join(" ")}})
end

However, when I open an irb session and type, say,

ri Proc

I do not get the documentation I'm seeking, just a return =>false.

"ri Proc" works fine for me from a command line. Can anyone suggest what
might be wrong?

Thanks

Brian
ruby 1.8.2, Windows XP
2 Answers

threeve.org

4/27/2005 1:31:00 PM

0

On 4/27/05, Brian Buckley <briankbuckley@gmail.com> wrote:
> Hello all,
>
> From p.191 of the pickaxe2 book, I put the following into my irb.rc file.
>
> def ri(*names)
> system(%{ri #{names.map {|name| name.to_s}.join(" ")}})
> end
>
> However, when I open an irb session and type, say,
>
> ri Proc
>
> I do not get the documentation I'm seeking, just a return =>false.
>
> "ri Proc" works fine for me from a command line. Can anyone suggest what
> might be wrong?
>
> Thanks
>
> Brian
> ruby 1.8.2, Windows XP
>
>

On windows it needs to be ri.bat, just like you should use irb.bat


Jason



Brian Buckley

4/27/2005 1:41:00 PM

0

That's it! Thank you.

Brian