Bug#867664: pandoc: Include doctype header in generated docbook output?

Jonas Smedegaard jonas at jones.dk
Sun Jul 9 10:58:33 UTC 2017


Quoting Petter Reinholdtsen (2017-07-08 12:31:26)
> 
> Package: pandoc
> Version: 1.12.4.2~dfsg-1
> 
> The DocBook output generated by pandoc is missing the XML header
> documenting the format.  Is there a reason for this?
> 
> Instead of getting this result,
> 
> % printf "header\n===\n\nbody\n"|pandoc -o - -t docbook -
> <sect1 id="header">
>   <title>header</title>
>   <para>
>     body
>   </para>
> </sect1>
> %
> 
> I suggest to return something like this:
> 
> % printf "header\n===\n\nbody\n"|pandoc -o - -t docbook -
> <?xml version="1.0" encoding='UTF-8' ?>
> <!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
>           "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd">
> <sect1 id="header">
>   <title>header</title>
>   <para>
>     body
>   </para>
> </sect1>
> %
> 
> This allow XML validators to check the content.

It seems Pandoc supports this already.

Perhaps you need to pass this option: --standalone

 - Jonas

-- 
 * Jonas Smedegaard - idealist & Internet-arkitekt
 * Tlf.: +45 40843136  Website: http://dr.jones.dk/

 [x] quote me freely  [ ] ask before reusing  [ ] keep private
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: signature
URL: <http://lists.alioth.debian.org/pipermail/pkg-haskell-maintainers/attachments/20170709/514e9d1a/attachment-0001.sig>


More information about the Pkg-haskell-maintainers mailing list