From owner-freebsd-doc Wed Jan 15 06:18:12 1997 Return-Path: Received: (from root@localhost) by freefall.freebsd.org (8.8.4/8.8.4) id GAA03835 for doc-outgoing; Wed, 15 Jan 1997 06:18:12 -0800 (PST) Received: from fallout.campusview.indiana.edu (fallout.campusview.indiana.edu [149.159.1.1]) by freefall.freebsd.org (8.8.4/8.8.4) with ESMTP id GAA03825 for ; Wed, 15 Jan 1997 06:18:09 -0800 (PST) Received: from localhost (jfieber@localhost) by fallout.campusview.indiana.edu (8.8.4/8.8.4) with SMTP id JAA07404; Wed, 15 Jan 1997 09:15:29 -0500 (EST) Date: Wed, 15 Jan 1997 09:15:28 -0500 (EST) From: John Fieber To: A JOSEPH KOSHY cc: freebsd-doc@FreeBSD.ORG Subject: Re: Any tutorials on docbook? In-Reply-To: <199701151351.AA253546261@fakir.india.hp.com> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-doc@FreeBSD.ORG X-Loop: FreeBSD.org Precedence: bulk On Wed, 15 Jan 1997, A JOSEPH KOSHY wrote: > Are there any tutorials on using DocBook? Do we have any examples of > Docbook use in the 3.0-current tree? Funny you should ask. I just started working on one yesterday. The resources that exist now include: The documentation that comes with Docbook is pretty good. It can be found at http://www.ora.com/davenport/dbdoc/. The user's guide and reference are the most relevant here. The reference contains document fragments illustrating each element in use. Sample documents. The docbook documentation is, naturally, written using docbook. I have some other documents, include the Digital Unix Technical Overview and System Administration Guide, the latter of which is larger than our own handbook. I'm also working on marking up the FreeBSD tutorials and will put them on the web as I have them done. I'll see about putting these together on a web page sometime today. An issue I'm still hammering out as I markup the sample documents is markup recommendations. Docbook is rich enough that you could potentially end up with more markup than content in your document! For example, in running text, you could have: ... rm -rf / ... or ... rm -rf / ... or ... rm / ... and so on. For running text, I tend to favor the first form, except when command syntax is being defined. The markup guide I'm working on will be not so much a guide to docbook, as a narrowing of its scope to something manageable. The other practical concern is that implementing all possible docbook constructs in a docbook -> whatever conversion is a huge task. I'm trying to identify *supported* constructs. The results of my automated linuxdoc to docbook conversion, unfortunately, do *not* yield good examples of docbook markup. Bunches of things that can be usefully marked up in docbook simply are not marked up because Linuxdoc has no equivalent elements (for example, tips and warnings) while others have a one to many mapping. Most in-line typographic treatment in Linuxdoc is done with ..., ... and .... Docbook does have a generic emphasis element, there is no equivalent to the others. My conversion tries out bunches of regex expressions on the content of ... and friends to guess the content (eg something with slashes, like /etc/sysconfig gets turned into /etc/sysconfig, rm -r becomes rm -r, and foo@bar.org becomes foo@bar.org. Unfortunately, there are limits to the accuracy and a fair number of things get mis-interpreted. Realizing that legacy documents would be converted to docbook, the creaters endowed every element with a "remap" attribute. When a ... or ... cannot be figured out, it just comes out as ... or .... The other notable difference is that the text used to identify a cross reference is specified where the reference is made in linuxdoc, while in docbook, it is specified (or inferred from) the target. Again, the remap attribute on the tag is used to simulate linuxdoc behavior, but that should *not* be used for any new documents. -john