[vox-tech] docbook to text

Steven Peck vox-tech@lists.lugod.org
Fri, 21 Jun 2002 00:01:44 -0700


No guarantees but have you seen this page?
http://www-106.ibm.com/developerworks/library/l-docbk.html#h9

Quote"
Exporting to plain text
DocBook also supports plain-text documents. To render a plain ASCII-text
document, use the following command:

sgmltools -b txt filename.sgml
End quote"

Overall it looks like a nice article.
http://www-106.ibm.com/developerworks/library/l-docbk.html

-sp

> -----Original Message-----
> From: vox-tech-admin@lists.lugod.org 
> [mailto:vox-tech-admin@lists.lugod.org] On Behalf Of Peter Jay Salzman
> Sent: Thursday, June 20, 2002 9:51 AM
> To: vox-tech@lists.lugod.org
> Subject: [vox-tech] docbook to text
> 
> 
> i'm trying to convert docbook sgml to text, and am having a 
> terrible time of it:
> 
> 
> 
> i tried using sgml2txt, but it complained that it didn't know 
> how to handle docbook.  it suggested that i use jade.
> 
> ok.
> 
> reading through jade's help files, it appears that jade 
> doesn't know how to convert sgml to text.  this is starting 
> to feel like UC davis's bureacracy.
> 
> ok.
> 
> i can convert docbook to html (obviously), so i try 
> html2text.  the results have wierd underscoring things in it. 
>  reading through the docs, there's a -nobs option which 
> produces pure text.
> 
> ok.
> 
> i try html2text with -nobs.  the results stink.  the 
> formating is all wrong.  there *should* be a blank line 
> between an <H[1-4]> line and the following text.  verbatim 
> text is all screwed up.
> 
> ok.
> 
> after some searching, i find 'man html2textrc'.   yuck.  i _really_
> don't want to read through this.  the rc file is complicated. 
>  i don't want to spend this amount of time for something as 
> simple as converting html to text.  i shouldn't have to spend 
> more than 5 minutes on such a simple operation.
> 
> ok.
> 
> i can convert man pages to text, so i use docbook-to-man and 
> convert the sgml file to a man page.  the results are worse 
> than awful.  it's completely unreadable.
> 
> 
> 
> are you feeling my pain yet?  this should be simple, and it's 
> turning out to be a nightmare.
> 
> does anyone have any ideas on how to convert a docbook file to text?
> 
> alternatively, if anyone has an .html2textrc file suitable 
> for FAQ style documents, i'd love to have a copy of your dotfile.
> 
> pete
> 
> 
> --
> GPG Fingerprint: B9F1 6CF3 47C4 7CD8 D33E  70A9 A3B9 1945 67EA 951D
> 
> _______________________________________________
> vox-tech mailing list
> vox-tech@lists.lugod.org 
> http://lists.lugod.org/mailman/listinfo/vox-> tech
>