Convert Mediawiki to Markdown (MediaWiki to GFM): Unterschied zwischen den Versionen
Aus Wiki-WebPerfect
Admin (Diskussion | Beiträge) (Die Seite wurde neu angelegt: „''I am using Mediawiki with the "Wikitext" syntax for many years, but now I'm at a point where I want to switch to the "Markdown" syntax.'' <br> ''Here I show…“) |
Admin (Diskussion | Beiträge) |
||
Zeile 1: | Zeile 1: | ||
''I am using Mediawiki with the "Wikitext" syntax for many years, but now I'm at a point where I want to switch to the "Markdown" syntax.'' <br> | ''I am using Mediawiki with the "Wikitext" syntax for many years, but now I'm at a point where I want to switch to the "Markdown" syntax.'' <br> | ||
− | ''Here I show you how you can "simply" switch your Mediawiki sites to Markdown files.'' | + | ''Here I show you how you can "simply" switch your Mediawiki sites to Markdown files.'' <br> |
+ | |||
+ | First thanks @PhilipAshlock and @OutOfControl for the great GitHub project that makes this even possbile: https://github.com/outofcontrol/mediawiki-to-gfm | ||
+ | |||
+ | |||
+ | == Requirements == | ||
+ | *PHP: Tested in PHP 7.0, 7.1 and 7.2 | ||
+ | <source lang="bash"> | ||
+ | sudo apt update | ||
+ | sudo apt -y install php7.3 | ||
+ | </source> | ||
+ | *Pandoc: Installation instructions are here https://pandoc.org/installing.html (Tested on version 2.0.1.1 and 2.0.2) | ||
+ | <source lang="bash"> | ||
+ | sudo apt install pandoc | ||
+ | </source> | ||
+ | *MediaWiki: https://www.mediawiki.org/wiki/MediaWiki (Tested on version 1.27.x and 1.29.x) | ||
+ | *Composer: Installation instructions are here https://getcomposer.org/download/ | ||
+ | <source lang="bash"> | ||
+ | sudo apt install php-xml | ||
+ | sudo apt install php-mbstring | ||
+ | |||
+ | php -r "copy('https://getcomposer.org/installer', 'composer-setup.php');" | ||
+ | php -r "if (hash_file('sha384', 'composer-setup.php') === '906a84df04cea2aa72f40b5f787e49f22d4c2f19492ac310e8cba5b96ac8b64115ac402c8cd292b8a03482574915d1a8') { echo 'Installer verified'; } else { echo 'Installer corrupt'; unlink('composer-setup.php'); } echo PHP_EOL;" | ||
+ | php composer-setup.php | ||
+ | php -r "unlink('composer-setup.php');" | ||
+ | </source> | ||
+ | |||
− | |||
Version vom 29. Oktober 2021, 13:31 Uhr
I am using Mediawiki with the "Wikitext" syntax for many years, but now I'm at a point where I want to switch to the "Markdown" syntax.
Here I show you how you can "simply" switch your Mediawiki sites to Markdown files.
First thanks @PhilipAshlock and @OutOfControl for the great GitHub project that makes this even possbile: https://github.com/outofcontrol/mediawiki-to-gfm
Requirements
- PHP: Tested in PHP 7.0, 7.1 and 7.2
sudo apt update sudo apt -y install php7.3
- Pandoc: Installation instructions are here https://pandoc.org/installing.html (Tested on version 2.0.1.1 and 2.0.2)
sudo apt install pandoc
- MediaWiki: https://www.mediawiki.org/wiki/MediaWiki (Tested on version 1.27.x and 1.29.x)
- Composer: Installation instructions are here https://getcomposer.org/download/
sudo apt install php-xml sudo apt install php-mbstring php -r "copy('https://getcomposer.org/installer', 'composer-setup.php');" php -r "if (hash_file('sha384', 'composer-setup.php') === '906a84df04cea2aa72f40b5f787e49f22d4c2f19492ac310e8cba5b96ac8b64115ac402c8cd292b8a03482574915d1a8') { echo 'Installer verified'; } else { echo 'Installer corrupt'; unlink('composer-setup.php'); } echo PHP_EOL;" php composer-setup.php php -r "unlink('composer-setup.php');"