deoren / notes

Various notes for topics I'm learning
2 stars 0 forks source link

Test Converting MediaWiki content to Markdown or reStructurtedText #46

Open deoren opened 5 years ago

deoren commented 5 years ago

Goals

References

deoren commented 5 years ago

Well, unless I missed something, this was super easy.

  1. lxc launch ubuntu:18.04 mediawiki-convert-test
  2. lxc exec mediawiki-convert-test -- /bin/bash
  3. sudo apt-get update && sudo apt-get install -y pandoc git texlive-latex-recommended texlive-xetex
  4. Visit https://wiki.whyaskwhy.org/index.php?title=Android&action=edit and copy raw content out (leaving out the leading categories entries, though this may have been fine to leave in)
  5. Save as input.txt
  6. pandoc -f mediawiki -t rst input.txt -o output.rst

Voila, reST format achieved.

deoren commented 5 years ago

Note: I used my notes from #3 to get started here with pandoc packages.