[Mediawiki-l] Export Wiki to DocBook??

Rowan Collins rowan.collins at gmail.com
Thu Dec 9 18:00:15 UTC 2004

On Thu, 09 Dec 2004 12:37:17 +0100, Florian Taeger <mail at konfu.de> wrote:
> I just found this site: http://meta.wikimedia.org/wiki/DocBook_XML_export
> But I am not able to find such a option in mediawiki? Is there the
> possibility to export the wiki to docbook format?

As far as I know, that has never been developed beyond the basic
proposal you just found. The biggest thing holding up something like
this is that the software's current "parser" isn't really a parser at
all, just a hideously complex series of global replacements. A couple
of attempts at replacing this with a proper grammar-based parser are
officially "in progress", but seem to have rather stalled. *

This leaves two options: 
1) write a tool (based on the linked Html2DocBook tool, perhaps) that
converts the specific HTML output by MediaWiki to appropriate DocBook
tags; this could be combined with the existing Special:Export if you
wanted to include metadata of any sort.
2) write a parser, perhaps by finishing one of those already
half-written*, that eats wiki-syntax and spits out some XML, that can
then be transformed into DocBook (and, hopefully, into XHTML, to
replace the current not-a-parser).

Option 1 is probably possible, although perhaps less satisfactory
(more compromises and odd hacks needed); option 2 is hard, but
eventually somebody's got to do it to keep the software from imploding
under the weight of its syntax.

* try searching the mailing list archives by Googling for
[site:mail.wikipedia.org "new parser"] (without quotes) or some
variation thereof.

Rowan Collins BSc

More information about the MediaWiki-l mailing list