Converting to Docbook format.

26 views
Skip to first unread message

Carlton Gibson

unread,
Sep 25, 2009, 6:46:47 AM9/25/09
to multim...@googlegroups.com
Hi all,

(Having lurked for an age...)

Does anybody know of a decent set of MMD to DocBook stylesheets?

Thanks,
Carlton

signinstranger

unread,
Sep 25, 2009, 8:02:58 AM9/25/09
to MultiMarkdown Discussion List
On Sep 25, 12:46 pm, Carlton Gibson <carlton.gib...@gmail.com> wrote:

> Does anybody know of a decent set of MMD to DocBook stylesheets?

I would try my luck with Pandoc[^1]. DocBook uses a hierarchical XML
format, which is very difficult to produce from MMD's flat XHTML
structure.


[^1]: http://johnmacfarlane.net/pandoc/

Carlton Gibson

unread,
Sep 25, 2009, 8:39:52 AM9/25/09
to signinstranger, MultiMarkdown Discussion List

Brilliant, thanks. I will give that a go.

signinstranger

unread,
Sep 25, 2009, 11:15:57 AM9/25/09
to MultiMarkdown Discussion List
On Sep 25, 2:39 pm, Carlton Gibson <carlton.gib...@gmail.com> wrote:

> > [^1]:http://johnmacfarlane.net/pandoc/
>
> Brilliant, thanks. I will give that a go.

Oh, maybe I should add that during the installation process under Mac
OS X, you will also need of a copy of Paul Wilson's "The Little Book
of Calm" within reach. ;-)

Fletcher T. Penney

unread,
Sep 25, 2009, 12:39:46 PM9/25/09
to signinstranger, MultiMarkdown Discussion List
By "hierarchical" vs "flat", do you mean in reference to
chapters/sections/etc?

You're correct that these are sister elements in MMD produced XHTML,
rather than parent-child elements. But XSLT is perfectly capable of
handling these and converting between the two. Several of my XSLT files
produce hierarchical output.

I have not installed haskell, and therefore have not used Pandoc. I
don't believe it replicates all of the syntax of MMD, but depending on
what features you need it is probably a viable option.

F-

> --~--~---------~--~----~------------~-------~--~----~
> You received this message because you are subscribed to the Google Groups "MultiMarkdown Discussion List" group.
> To post to this group, send email to multim...@googlegroups.com
> To unsubscribe from this group, send email to multimarkdow...@googlegroups.com
> For more options, visit this group at http://groups.google.com/group/multimarkdown?hl=en
> -~----------~----~----~----~------~----~------~--~---
>

--
Fletcher T. Penney
fletche...@gmail.com

Nothing worth doing can be done overnight.
- from the Kevin Costner movie, The Postman
(Might have to think long and hard about this one...)

signinstranger

unread,
Sep 25, 2009, 2:59:14 PM9/25/09
to MultiMarkdown Discussion List
On Sep 25, 6:39 pm, "Fletcher T. Penney" <fletcher.pen...@gmail.com>
wrote:
> By "hierarchical" vs "flat", do you mean in reference to
> chapters/sections/etc?
>
> You're correct that these are sister elements in MMD produced XHTML,
> rather than parent-child elements.  But XSLT is perfectly capable of
> handling these and converting between the two.  Several of my XSLT files
> produce hierarchical output.

Sorry, I exaggerated the problem. There already are some XHTML-to-
DocBook
stylesheets available, so it can be done. But Pandoc does a good job,
if
you get it installed (and that's a big IF)

Carlton Gibson

unread,
Sep 28, 2009, 5:18:42 AM9/28/09
to Fletcher T. Penney, signinstranger, MultiMarkdown Discussion List

On 25 Sep 2009, at 17:39, Fletcher T. Penney wrote:

> By "hierarchical" vs "flat", do you mean in reference to chapters/
> sections/etc?
>
> You're correct that these are sister elements in MMD produced XHTML,
> rather than parent-child elements. But XSLT is perfectly capable of
> handling these and converting between the two. Several of my XSLT
> files produce hierarchical output.


Thanks for the input. I will look at the existing stylesheets and
think about modifying them.

My situation is just that I'm learning Docbook (which appears to be
_expansive_ rather than _difficult_ per se). As such I'm after
something that will get me started -- I can come back to create my own
stylesheets later :-)

An existing XHTML to Docboom stylesheet would be perfect but failing
that I'll give Pandoc a try. (I'm thinking the Ubuntu package may be
the way to go...)

thanks again,
Carlton

Reply all
Reply to author
Forward
0 new messages