Table of Contents
Converting Google Docs to Dokuwiki Markdown Format
Software
You will want to install install_panadoc which is open source software that will help translate from Google Docs to Dokuwiki
Steps
1. Download Google Doc as a .docx Word Document. File > Download > Microsoft Word
2. Open Command Prompt and locate location of downloaded folder
3. Run pandoc to convert the document
pandoc "Downloads/Prusa MK2s 3D Printer Tool Tutorial.docx" -f docx -t dokuwiki -o "Downloads/prusa.txt"
4. Next you will probably want to open the file in a text editor that has search and replace functionality. I've found that bulleted lists don't covert over cleanly and are rendered with html instead. you can use a search and replace text editor to quickly clean that up.
Replace:
- <HTML><p></HTML> with nothing
- <HTML></p></HTML> with nothing
- <HTML></li></HTML> with nothing
- <HTML><ul></HTML> with nothing
- <HTML><li></HTML>> following ul with “ * ” (two spaces before asterisk and one after)
- <HTML><ol></HTML> with nothing
- <HTML><li></HTML>> following ol with “ - ” (two spaces before hyphen and one after)
5. Create new dokuwiki page by entering a url that does not exists and click create
6. In the Google doc for each image do the following:
- Right Click, Choose View More Actions, then Save to Keep.
- Download from the keep pane that opens on the right.
- Rename so that the file has similar naming to the wiki page
- use the Media Manager under the search box in dokuwiki to upload the images.
- link them back in the doc where they belong
6. paste in updated text, preview and clean up.