# Textile / RedCloth to PDF converter?

**URL:** <https://www.ruby-forum.com/t/textile-redcloth-to-pdf-converter/67069>\
**Category:** Ruby\
**Created:** [August 31, 2006, 12:47pm UTC](https://www.ruby-forum.com/t/textile-redcloth-to-pdf-converter/67069 "2006-08-31T12:47:27Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![justbe](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/j/74df32/32.png) [@justbe](https://www.ruby-forum.com/u/justbe)\
**Post date:** [August 31, 2006, 12:47pm UTC](https://www.ruby-forum.com/t/textile-redcloth-to-pdf-converter/67069/1 "2006-08-31T12:47:27Z")

</div>

Hey there,

I am currently looking for a good / stable way to create .pdf-files out  
of a textile formated text. Does anyone know whether someone already  
wrote a textile =\> e.g. PDF::Writer library? Or is there any other  
reliable way that allows me to create a pdf-file including the  
formating of the original formatted text?

Cheers & thanks,  
-Joerg

---

<div class="post-metadata">

**Author:** ![justbe](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/j/74df32/32.png) [@justbe](https://www.ruby-forum.com/u/justbe)\
**Post date:** [August 31, 2006, 1:51pm UTC](https://www.ruby-forum.com/t/textile-redcloth-to-pdf-converter/67069/2 "2006-08-31T13:51:38Z")

</div>

On Thu, 31 Aug 2006 06:45:35 -0400, Joerg B.  
[removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid) wrote:

> Hey there,
> 
> I am currently looking for a good / stable way to create .pdf-files out  
> of a textile formated text. Does anyone know whether someone already  
> wrote a textile =\> e.g. PDF::Writer library? Or is there any other  
> reliable way that allows me to create a pdf-file including the  
> formating of the original formatted text?

I have this in a file called textile2pdf. Not sure where it came from:

pdf=`basename $1 .txt`.pdf

redcloth $1 |   
sed -e “s/’/&#39;/” |   
htmldoc --cont --format pdf14 - \>`basename $1 .txt`.pdf

htmldoc is availble here:

[http://www.easysw.com/products.php](http://www.easysw.com/products.php)

Regards,  
JJ

---

<div class="post-metadata">

**Author:** ![justbe](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/j/74df32/32.png) [@justbe](https://www.ruby-forum.com/u/justbe)\
**Post date:** [August 31, 2006, 4:14pm UTC](https://www.ruby-forum.com/t/textile-redcloth-to-pdf-converter/67069/3 "2006-08-31T16:14:03Z")

</div>

John,

thanks! I was looking for a somewhat more ‘integrated’ way, but it  
seems this isn’t something that has been created yet.

thanks and all the best,  
-joerg
