[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]
Subject: Re: [docbook-apps] validating individual files in a document
http://www.sagehill.net/docbookxsl/ModularDoc.htmlIf you can convert the book to use XInclude instead, you could add a DOCTYPE to each module and validate the book and the modules individually.
Short of that, you could create "shadow" files. For each system entity, create an XML document consisting of a DOCTYPE and a reference to that system entity. You could validate each of those. Since they don't contain any content, they don't require updates as the book progresses. And your book still references the system entities, not the shadow files.
Bob Stayton Sagehill Enterprises bobs@sagehill.net On 7/17/2016 5:35 PM, Joseph Mingrone wrote:
Hi Bob, Bob Stayton <bobs@sagehill.net> writes:Hi Joseph, If you can put a DOCTYPE declaration at the top of the included file, then you must be using XInclude and not system entity references to assemble your document. If you are using XInclude, it is not an error to define the entities in DOCTYPES in both the main document and the included document. The rules are described in this section of my online book on DocBook XSL:http://www.sagehill.net/docbookxsl/ModularDoc.html#XincludeTextEntitiesThere's also a section on managing such shared entity declarations:http://www.sagehill.net/docbookxsl/ModularEntities.htmland lots of other tips on using XInclude.I can put a DTD at the top of the included file and it validates in Emacs. <!DOCTYPE book [ <!ENTITY % prompt.user SYSTEM "../../../../share/xml/freebsd.ent"> %prompt.user; <!ENTITY % man.csh.1 SYSTEM "../../../../share/xml/man-refs.ent"> %man.csh.1; ]> But, if I do that, putting the book together by running make on the supplied Makefile fails. It does not look like this book is using XInclude. <books/fdp-primer> % grep -ir xinclude . returns nothing. Is there a way, other than creating a DTD in the included file, to satisfy the validator when it's only validating that included file? Maybe I'll look into configuring nxml-mode to ignore the missing entity definitions. Thanks, Joseph
[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]