Converting wiki to DocBook XML

Useful References
http://fedoraproject.org/wiki/DocsProject/WorkFlow#WikitoDocBookXML

Before Conversion
The document needs to follow these lengthy but accurate guidelines:


 * http://fedoraproject.org/wiki/DocsProject/WritingUsingTheWiki
 * http://fedoraproject.org/wiki/WikiEditing#Linking
 * http://fedoraproject.org/wiki/WikiEditing#Lists
 * http://fedoraproject.org/wiki/WikiEditing#Tables
 * http://fedoraproject.org/wiki/WikiEditing#Notes,_Tips,_and_Other_Admonitions
 * http://fedoraproject.org/wiki/WikiEditing#Marking_Technical_Terms
 * http://fedoraproject.org/wiki/WikiEditing#Writing_Example_Commands
 * http://fedoraproject.org/wiki/DocsProject/StyleGuide

Converting to XML

 * 1) Install   package.
 * 2) Run this command to render one page:
 * 3) Make a script or for-loop to iterate through a list of pages.

If you have more than a few files, you may want to use this process to make it easier:

Chapter_One_-_Called_something Chapter_Two_-_Called_another_thing ... mkdir XML_files for i in `cat /tmp/wiki_files`; do /usr/bin/mw-render -c http://fedoraproject.org/w/ -w docbook $i -o XML_files/$i.xml; done
 * Make a plain text file  with the name of each wiki article on a line by itself.  The name should include the underscore '_' instead of spaces, but no brackets or file extensions:
 * Use this for-loop to iterate through each file, rendering it to XML:

Processing DocBook Pages
Follow this process guideline with each XML file:


 * 1) Open the file in a full-featured text editor
 * 2) Ensure the XML file has the proper header, with proper chapters or sections
 * 3) Change to 'chapter' type
 * 4) Remove extraneous XML stylesheet call
 * 5) Change XML file type within the file
 * 6) book => 0
 * 7) article => chapter
 * 8) articleinfo => 0
 * 9) Search through the file for each of the markup output types covered in [#Wiki_markup_output_to_XML,_mapped_to_DocBook_XML Wiki markup output to XML, mapped to DocBook XML] ; that is, do the following:
 * 10) Search for each instance of 'emphasis' and replace it with the proper DocBook contextual markup
 * 11) Search for each instance of 'code' and 'programlisting' and replace it with the proper DocBook contextual markup
 * 12) Search and replace empty literallayout containers
 * 13) Convert inlinemediaobject to proper admonition

Wiki markup output to XML, mapped to DocBook XML
Was two-ticks in wiki \=> =>, , , , ,                      , , , ,                        , , , ,

Was three-ticks in Wiki \=> =>

Was  content allows you type anything verbatim between the markers. This means you don't have to change special characters like  into their XML character entity equivalents. This simplifies the process somewhat, but you can't use any XML tags between the  markers, of course. Avoid putting in extra space such as line breaks.

ulink (URLs)
To make a link to a URL: Visit my page at .

It's best not to hyperlink other text because in some formats people may have a hard time finding the actual URL. Edit judiciously.