DOCBOOK2TEXI-SPEC.PL(1)

🌸 NAME 🌸

okay bestie, welcome to the docbook2texi-spec.pl(1) page β€” home of docbook2texi-spec.pl. The NAME line says it’s here to convert DocBook Booksto Texinfo documents (yes, β€˜Booksto’ is literally what the source says, no cap 😭), and honestly that’s the whole assignment. πŸ’…


✨ SYNOPSIS ✨

copy these exactly, bestie β€” no autocorrect, especially that first line πŸ’€:

sgmlspl docbook2man-spec.pl

nsgmls [ sgml document ]| sgmlspl docbook2texi-spec.pl [ basename ]

πŸ’– DESCRIPTION πŸ’–

docbook2texi is a sgmlspl spec file that produces GNU Texinfo documents from DocBook documents. it’s giving converter energy. ✨

The program reads ESIS produced by nsgmls (or other SGML parsers) from standard input. Currently the document element must be Book, otherwise the results are undefined β€” so do not test fate, bestie. πŸ’€

Its output, the converted Texinfo document, is written to standard output. slay.

The file basename.refs will also be created, which contains all the nodes in the document and their immediate 'child' nodes. As node processing always require forward references, docbook2texi must be run twice for each document: the first time to build the references, and the second to actually generate a valid document. yes, twice β€” first for the refs, second for the real valid document. πŸ”


πŸŽ€ REQUIREMENTS πŸŽ€

The SGMLSpm package from CPAN. This package includes the sgmlspl script that is also needed. that’s the whole requirements list β€” CPAN package, plus the sgmlspl script inside it. 🫢


πŸ’€ LIMITATIONS πŸ’€

Trying docbook2man on non-DocBook or non-conformant SGML results in undefined behavior. :-) yes, docbook2man β€” that’s what the page says, don’t come for me 😭

This program is a slow, dodgy Perl script. no cap, it says so itself. πŸ’€

This program does not come close to supporting all the possible markup in DocBook, and may produce wrong output in some cases with supported markup. so like, vibe check your output. 🫠


πŸ¦‹ TO DO πŸ¦‹

  • How the hell do you represent a backslash (\) in Texinfo!!@? I've tried \\ but TeX complains about it. 😭 like, make it make sense.
  • Fix breakages found in the test documents. πŸ§ͺ
  • Add new element handling and fix existing handling. Be robust. πŸ’ͺ
  • Make it faster. I think most of the speed problems so far is with parsing ESIS. Rewrite SGMLS.pm with C and/or get input directly from SP. πŸ”₯
  • There are some dependencies on elements occurring when they are actually optional (according to the DTD). We need to fix that (preferably) or prominently state the requirements. 🫠
  • Allow other more common document elements. 🌈
  • Separate out node referencing to a separate script. Not only would it make it faster/easier to maintain because it's separate from the main code, but also I would like it to evolve into an automatic DocBook ToC generator. πŸŽ€

Copyright (C) 1998-1999 Steve Cheng <steve@ggi-project.org>

This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2, or (at your option) any later version. πŸ’–

You should have received a copy of the GNU General Public License along with this program; see the file COPYING. If not, please write to the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. 🫢

and that’s the page, bestie β€” docbook2texi-spec.pl(1), 05 December 2025. byeeee, go be iconic with your Texinfo πŸ’…βœ¨

πŸ“¦ where this page comes from