Attempting to document everything in CVS I did (slightly trimmed):
----------8<-----------------
#!/bin/sh -x
PATH=/scratch/local/bin:$PATH; export PATH
echo $PATH
OUTPUTDIR=/home/hgs/public_html/ruby/rubycvsdocs
if test -d $OUTPUTDIR; then
echo deleting $OUTPUTDIR
/bin/rm -rf $OUTPUTDIR
fi
if test -f rubycvsdocs.zip; then
echo deleting rubycvsdocs.zip
/bin/rm -f rubycvsdocs.zip
fi
cd /scratch/hgs/rubycvs/ruby
rdoc -a -S -o $OUTPUTDIR
----------8<-----------------
but it didn't descend into all the subdirs of lib. So I added a *
argument:
rdoc -a -S -o $OUTPUTDIR *
because I could see no way to force descent of
subdirectories of subdirectories, and thought this might at least
get me closer to what I wanted. It failed thusly:
Generating HTML...
/scratch/local/lib/ruby/1.9/rdoc/code_objects.rb:328:in `find_symbol': stack
level too deep (SystemStackError)
from /scratch/local/lib/ruby/1.9/rdoc/code_objects.rb:328:in
`find_symbol'
from /scratch/local/lib/ruby/1.9/rdoc/code_objects.rb:328:in
`find_symbol'
from /scratch/local/lib/ruby/1.9/rdoc/code_objects.rb:328:in
`find_symbol'
from /scratch/local/lib/ruby/1.9/rdoc/code_objects.rb:328:in
`find_symbol'
from /scratch/local/lib/ruby/1.9/rdoc/code_objects.rb:328:in
`find_symbol'
from /scratch/local/lib/ruby/1.9/rdoc/code_objects.rb:328:in
`find_symbol'
from /scratch/local/lib/ruby/1.9/rdoc/code_objects.rb:328:in
`find_symbol'
from /scratch/local/lib/ruby/1.9/rdoc/code_objects.rb:328:in
`find_symbol'
... 3182 levels...
from
/scratch/local/lib/ruby/1.9/rdoc/generators/html_generator.rb:1182:in
`generate_html'
from
/scratch/local/lib/ruby/1.9/rdoc/generators/html_generator.rb:1107:in `generate'
from /scratch/local/lib/ruby/1.9/rdoc/rdoc.rb:269:in `document'
from /scratch/local/bin/rdoc:63
So, is this reproducible, and is there a better way to invoke rdoc
to get what I want? I expect I've missed something despite
reviewing rdoc --help. The -r and -R options are to do with ri, not
recursion, and I didn't see other options that looked like what I
was after.
Thank you,
Hugh
|