-
Notifications
You must be signed in to change notification settings - Fork 6
Going from ODT to Github Wiki
bunnie edited this page Jun 13, 2021
·
1 revision
- Edit file in LibreOffice. In my process, I annotate URLs using markdown syntax and paste pictures directly into the document. I also use the native "headers" style to indicate sections.
-
unzip
the.odt
file. It turns out.odt
is nothing more than a ZIP file. There will be a directory ofPictures
. - Rename
Pictures
to something unique and copy it into the Wiki github ([email protected]:betrusted-io/betrusted-wiki.wiki.git
) - Export the ODT text to HTML using
pandoc
:pandoc -s --metadata pagetitle=whatever -o temp.html original.odt
- Export HTML to Markdown:
pandoc -f html -s -t markdown temp.html -o md_to_github.md
- Open the .md in an editor (
vscode
withMarkdown All in One
for example), and search/replacePictures/
with a URL of the formhttps://raw.githubusercontent.com/wiki/betrusted-io/betrusted-wiki/pictures_monitoring/
. Push the changes to github. - Search and replace instances of
\
with nothing (of course paying attention to e.g. Windows paths or legit uses of ) - You should be able to preview the markdown, complete with pictures, by doing Ctrl-Shift-V.
- Add a ToC by doing Ctr-Shift-P and going to
Markdown All in One: Create Table of Contents
. - Add the resulting .md file to the wiki.