While we're discussing 'ri'...

H

Hal Fulton

I have a confession. 'ri' has never worked for me, and I have never
tracked down the reason(s) why.

I have the following files on my system named ri... the first one is
the one in my path.

/usr/local/bin/ri
/usr/local/lib/ruby/1.8/rdoc/ri
/usr/local/share/ri
/usr/src/self/ruby-1.8.1/bin/ri
/usr/src/self/ruby-1.8.1/lib/rdoc/ri

And that one doesn't even respond to -v, but --help says that it's
"alpha 0.1" which sounds ancient to me.

What's the shortest path from here to sanity?


Hal
 
D

Dave Thomas

What's the shortest path from here to sanity?

Can't help you there, but to get ri working, I suggest (assuming you're
running from a source distribution)

1. Delete everything on your system that has 'ri' in the path.
2. Do the same for rdoc
3. do a 'make install'

If you're installing from Curt's Window's installer, then uninstall the
previous version and install his new one which has ri and rdoc
configured correctly.


Cheers

Dave
 
H

Hal Fulton

Dave said:
Can't help you there,

I asked for that, didn't I? :) "My mind is going, Dave..."
but to get ri working, I suggest (assuming you're
running from a source distribution)

[snip]

OK, will try that.
If you're installing from Curt's Window's installer, then uninstall the
previous version and install his new one which has ri and rdoc
configured correctly.

I avoid Windows as much as possible these days. But I will get around
to reinstalling sometime soon. I'm glad for the work Curt has done, and
you and Andy prior to that.


Hal
 
H

Hal Fulton

Hal said:
but to get ri working, I suggest (assuming you're running from a
source distribution)


[snip]

OK, will try that.

Hmm, doesn't work for me. I think I'll probably just switch to
1.8.2 or cvs and compile/install from scratch. Surely that will
fix it.


Hal
 
J

James Britt

Hal said:
I have a confession. 'ri' has never worked for me, and I have never
tracked down the reason(s) why.

I have the following files on my system named ri... the first one is
the one in my path.

/usr/local/bin/ri
/usr/local/lib/ruby/1.8/rdoc/ri
/usr/local/share/ri
/usr/src/self/ruby-1.8.1/bin/ri
/usr/src/self/ruby-1.8.1/lib/rdoc/ri

And that one doesn't even respond to -v, but --help says that it's
"alpha 0.1" which sounds ancient to me.

What's the shortest path from here to sanity?

I grabbed the latest 1.8.2 source.
I ran the usual: autoconf, configure, make, make install.
ri failed.
I looked inside Makefile and see the target install-doc.
I ran make install-doc.
ri worked.

Not the most obvious path for me, but there you go.

James
 
H

Hal Fulton

James said:
I grabbed the latest 1.8.2 source.
I ran the usual: autoconf, configure, make, make install.
ri failed.
I looked inside Makefile and see the target install-doc.
I ran make install-doc.
ri worked.

Not the most obvious path for me, but there you go.

I'm trying that now. Sounds like it should be added so that
it happens automagically.

Out of curiosity: Does 'make test' work for you? It fails
for me, but the build seems ok...


Hal
 
D

Dave Thomas

I ran make install-doc.
ri worked.

Not the most obvious path for me, but there you go.

Perhaps you might mention that over on ruby-core...

Cheers

Dave
 
C

Charles Comstock

Hal said:
I'm trying that now. Sounds like it should be added so that
it happens automagically.

Out of curiosity: Does 'make test' work for you? It fails
for me, but the build seems ok...


Hal
When you configure do a --enable-install-doc and then it will
autoinstall as you build. Personally I think that should be the default
and --disable-install-doc should be the option if say you were rapidly
recompiling the ruby source.

Charles Comstock
 
M

Mauricio Fernández

I'm trying that now. Sounds like it should be added so that
it happens automagically.

Some of the core devels opposed that since they build several times a
day and don't want to waste time regenerating ri data files.
OTOH there could be another target with no ri docs for them...
Out of curiosity: Does 'make test' work for you? It fails
for me, but the build seems ok...

Works for me with a fairly old tarball (ruby 1.8.2 2004-06-28).

--
Running Debian GNU/Linux Sid (unstable)
batsman dot geo at yahoo dot com

All the existing 2.0.x kernels are to buggy for 2.1.x to be the
main goal.
-- Alan Cox
 
J

James Britt

Dave said:
Perhaps you might mention that over on ruby-core...

I just might. I believe there was previous discussion there on whether
rdocs/ri should be installed by default or not; I'd vote Yes (and may
have even said so at the time), but I don't recall what the counter
arguments were.

James
 
J

James Britt

Charles said:
When you configure do a --enable-install-doc and then it will
autoinstall as you build. Personally I think that should be the default
and --disable-install-doc should be the option if say you were rapidly
recompiling the ruby source.

I don't recall that even being mentioned when I did ./configure --help.

I had remembered something along those lines from a thread on ruby-core,
but did not see any option listed to tell configure to do this.


James
 
J

James Britt

James said:
I don't recall that even being mentioned when I did ./configure --help.

I had remembered something along those lines from a thread on ruby-core,
but did not see any option listed to tell configure to do this.

But, indeed, it *is* there, last item in right before Optional Features.

James
 
S

Sean O'Dell

I just might. I believe there was previous discussion there on whether
rdocs/ri should be installed by default or not; I'd vote Yes (and may
have even said so at the time), but I don't recall what the counter
arguments were.

Why not split Ruby into two distributions, the core Ruby binaries and
libraries needed to run Ruby scripts, and a developer distribution which
contains irb, ri, rdocs and anything else a Ruby developer would need.

Sean O'Dell
 
C

Cameron McBride

When you configure do a --enable-install-doc and then it will
autoinstall as you build. Personally I think that should be the default
and --disable-install-doc should be the option if say you were rapidly
recompiling the ruby source.

Just to add another vote, I think it'd be really useful to have that
--enable-install-doc as the default.

Cameron
 
C

Charles Comstock

Mauricio said:
Some of the core devels opposed that since they build several times a
day and don't want to waste time regenerating ri data files.
OTOH there could be another target with no ri docs for them...

Right I understand why it would bother them, but it doesn't seem to hard
to make it --disable-install-docs as a configure option and then
everytime they do a new make they don't have that extra step.

Charles Comstock
 
C

Charles Comstock

Sean said:
Why not split Ruby into two distributions, the core Ruby binaries and
libraries needed to run Ruby scripts, and a developer distribution which
contains irb, ri, rdocs and anything else a Ruby developer would need.

Sean O'Dell

irb, ri, rdocs etc are all very small. All the documentation is from
the actual source, it's a question as to whether they should be
generated automatically that's all. I don't really think that warrants
splitting the distribution. I'm just suggesting you can disable it with
--disable-install-doc as a configure option, and have enable the default.

Charles Comstock
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Staff online

Members online

Forum statistics

Threads
473,995
Messages
2,570,230
Members
46,816
Latest member
SapanaCarpetStudio

Latest Threads

Top