# Novice question about rdoc

**URL:** <https://rubytalk.org/t/novice-question-about-rdoc/51014>\
**Category:** ruby-talk\
**Created:** [6 January 2009 16:53 UTC](https://rubytalk.org/t/novice-question-about-rdoc/51014 "2009-01-06T16:53:44Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Bernard\_Lambeau1](https://avatars.discourse-cdn.com/v4/letter/b/ce73a5/32.png) [@Bernard\_Lambeau1](https://rubytalk.org/u/Bernard_Lambeau1)\
**Post date:** [6 January 2009 16:53 UTC](https://rubytalk.org/t/novice-question-about-rdoc/51014/1 "2009-01-06T16:53:44Z")

</div>

I've got a stupid problem with rdoc, and I don't find any answer on  
the web. Sorry ...

Is there an option to force rdoc to generate the html documentation  
each time it is invoked? I use the following task in Rakefile:

desc "Generates documentation"  
Rake::RDocTask.new do |rdoc|  
&nbsp;&nbsp;rdoc.rdoc\_files.include( "README", "INSTALL",  
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;"TODO", "CHANGELOG",  
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;"AUTHORS", "COPYING",  
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;"lib/" )  
&nbsp;&nbsp;rdoc.main = "README"  
&nbsp;&nbsp;rdoc.rdoc\_dir = "doc/html"  
&nbsp;&nbsp;rdoc.title = "Stamina Documentation"  
&nbsp;&nbsp;rdoc.options \<\< "-S" \<\< "-N" \<\< "-p" \<\< "-H"  
end

rake rdoc generates the documentation only the first time. After, it  
does not generate anything unless I remove the doc/html folder.

blambeau

---

<div class="post-metadata">

**Author:** ![Brian\_Candler](https://avatars.discourse-cdn.com/v4/letter/b/5f9b8f/32.png) [@Brian\_Candler](https://rubytalk.org/u/Brian_Candler)\
**Post date:** [6 January 2009 19:13 UTC](https://rubytalk.org/t/novice-question-about-rdoc/51014/2 "2009-01-06T19:13:24Z")

</div>

LAMBEAU Bernard wrote:

> rake rdoc generates the documentation only the first time. After, it  
> does not generate anything unless I remove the doc/html folder.

Try: rake rerdoc

&nbsp;&nbsp;# Rebuild the rdoc files from scratch, even if they are not out  
&nbsp;&nbsp;# of date.

> **···**
>
> --  
> Posted via [http://www.ruby-forum.com/\](http://www.ruby-forum.com/%5C).

---

<div class="post-metadata">

**Author:** ![Ryan\_Davis1](https://yyz1.discourse-cdn.com/flex029/user_avatar/rubytalk.org/ryan_davis1/32/1848_2.png) [@Ryan\_Davis1](https://rubytalk.org/u/Ryan_Davis1)\
**Post date:** [7 January 2009 21:51 UTC](https://rubytalk.org/t/novice-question-about-rdoc/51014/3 "2009-01-07T21:51:07Z")

</div>

\*nod\*

or:

task :rdoc =\> :clobber\_docs

> **···**
>
> On Jan 6, 2009, at 11:13 , Brian Candler wrote:
> 
> > LAMBEAU Bernard wrote:
> > 
> > > rake rdoc generates the documentation only the first time. After, it  
> > > does not generate anything unless I remove the doc/html folder.
> > 
> > Try: rake rerdoc
> > 
> > # Rebuild the rdoc files from scratch, even if they are not out  
> > # of date.
