# How to force RDoc not to parse a file?

**URL:** <https://www.ruby-forum.com/t/how-to-force-rdoc-not-to-parse-a-file/172831>\
**Category:** Ruby\
**Created:** [July 28, 2009, 6:30pm UTC](https://www.ruby-forum.com/t/how-to-force-rdoc-not-to-parse-a-file/172831 "2009-07-28T18:30:41Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![ISSSSaki\_Baz\_C](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/i/51bf81/32.png) [@ISSSSaki\_Baz\_C](https://www.ruby-forum.com/u/ISSSSaki_Baz_C)\
**Post date:** [July 28, 2009, 6:30pm UTC](https://www.ruby-forum.com/t/how-to-force-rdoc-not-to-parse-a-file/172831/1 "2009-07-28T18:30:41Z")

</div>

Hi, I want to include a text file (LICENSE.txt) in the RDoc  
documentation. However, I don’t want RDoc to parse it, instead, I want  
it to be displayed as text format.  
Is it possible with some commandline option of rdoc? I’ve not found  
it…

Thanks.

---

<div class="post-metadata">

**Author:** ![ISSSSaki\_Baz\_C](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/i/51bf81/32.png) [@ISSSSaki\_Baz\_C](https://www.ruby-forum.com/u/ISSSSaki_Baz_C)\
**Post date:** [July 28, 2009, 6:54pm UTC](https://www.ruby-forum.com/t/how-to-force-rdoc-not-to-parse-a-file/172831/2 "2009-07-28T18:54:25Z")

</div>

IÃ±aki Baz C. wrote:

> Hi, I want to include a text file (LICENSE.txt) in the RDoc  
> documentation. However, I don’t want RDoc to parse it, instead, I want  
> it to be displayed as text format.  
> Is it possible with some commandline option of rdoc? I’ve not found  
> it…
> 
> Thanks.

Did you try rdoc --help?

```
   --exclude, -x pattern
                        do not process files or directories matching
                        pattern. Files given explicitly on the 

```

command  
line will never be excluded.

---

<div class="post-metadata">

**Author:** ![ISSSSaki\_Baz\_C](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/i/51bf81/32.png) [@ISSSSaki\_Baz\_C](https://www.ruby-forum.com/u/ISSSSaki_Baz_C)\
**Post date:** [July 28, 2009, 7:04pm UTC](https://www.ruby-forum.com/t/how-to-force-rdoc-not-to-parse-a-file/172831/3 "2009-07-28T19:04:38Z")

</div>

Tim H. wrote:

> ```
> --exclude, -x pattern
> do not process files or directories matching
> pattern. Files given explicitly on the 
> 
> ```
> 
> command  
> line will never be excluded.

Maybe he wanted to suppress markup but still include the file in the  
rdoc output and index listing. That seems reasonable for LICENSE.txt.

---

<div class="post-metadata">

**Author:** ![ISSSSaki\_Baz\_C](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/i/51bf81/32.png) [@ISSSSaki\_Baz\_C](https://www.ruby-forum.com/u/ISSSSaki_Baz_C)\
**Post date:** [July 28, 2009, 7:12pm UTC](https://www.ruby-forum.com/t/how-to-force-rdoc-not-to-parse-a-file/172831/4 "2009-07-28T19:12:15Z")

</div>

2009/7/28 Joel VanderWerf [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid):

> > Did you try rdoc --help?
> > 
> > Â Â Â --exclude, -x pattern  
> > Â Â Â Â Â Â Â Â Â Â Â Â Â Â do not process files or directories matching  
> > Â Â Â Â Â Â Â Â Â Â Â Â Â Â pattern. Files given explicitly on the command  
> > Â Â Â Â Â Â Â Â Â Â Â Â Â Â line will never be excluded.
> 
> Maybe he wanted to suppress markup but still include the file in the rdoc  
> output and index listing. That seems reasonable for LICENSE.txt.

Yes, that is exactly what I want.

---

<div class="post-metadata">

**Author:** ![ISSSSaki\_Baz\_C](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/i/51bf81/32.png) [@ISSSSaki\_Baz\_C](https://www.ruby-forum.com/u/ISSSSaki_Baz_C)\
**Post date:** [July 28, 2009, 8:14pm UTC](https://www.ruby-forum.com/t/how-to-force-rdoc-not-to-parse-a-file/172831/5 "2009-07-28T20:14:54Z")

</div>

On Jul 28, 2009, at 10:11 , Iñaki Baz C. wrote:

> > Maybe he wanted to suppress markup but still include the file in  
> > the rdoc  
> > output and index listing. That seems reasonable for LICENSE.txt.
> 
> Yes, that is exactly what I want.

I don’t think you can do that. File a feature request on the rdoc  
project on rubyforge.

---

<div class="post-metadata">

**Author:** ![ISSSSaki\_Baz\_C](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/i/51bf81/32.png) [@ISSSSaki\_Baz\_C](https://www.ruby-forum.com/u/ISSSSaki_Baz_C)\
**Post date:** [July 28, 2009, 7:06pm UTC](https://www.ruby-forum.com/t/how-to-force-rdoc-not-to-parse-a-file/172831/6 "2009-07-28T19:06:47Z")

</div>

Joel VanderWerf wrote:

> Maybe he wanted to suppress markup but still include the file in the  
> rdoc output and index listing. That seems reasonable for LICENSE.txt.

You’re right. I didn’t read his post carefully enough.

---

<div class="post-metadata">

**Author:** ![ISSSSaki\_Baz\_C](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/i/51bf81/32.png) [@ISSSSaki\_Baz\_C](https://www.ruby-forum.com/u/ISSSSaki_Baz_C)\
**Post date:** [July 28, 2009, 10:46pm UTC](https://www.ruby-forum.com/t/how-to-force-rdoc-not-to-parse-a-file/172831/7 "2009-07-28T22:46:31Z")

</div>

El Martes, 28 de Julio de 2009, Ryan D.  
escribió:\> \>\>

> > > Maybe he wanted to suppress markup but still include the file in  
> > > the rdoc  
> > > output and index listing. That seems reasonable for LICENSE.txt.
> > 
> > Yes, that is exactly what I want.
> 
> I don’t think you can do that. File a feature request on the rdoc  
> project on rubyforge.

Done 🙂
