Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/jwflory/bw
(bw == "Bye Wiki") Say goodbye to your wikis! Python command-line tool to convert MediaWiki pages to other formats with pandoc
https://github.com/jwflory/bw
asciid asciidoc asciidoctor cli command-line command-line-tool documentation-tool markdown mediawiki mediawiki-wikis pandoc python python3 wiki wikis
Last synced: 3 months ago
JSON representation
(bw == "Bye Wiki") Say goodbye to your wikis! Python command-line tool to convert MediaWiki pages to other formats with pandoc
- Host: GitHub
- URL: https://github.com/jwflory/bw
- Owner: jwflory
- License: bsd-3-clause
- Created: 2019-09-28T23:01:24.000Z (over 5 years ago)
- Default Branch: main
- Last Pushed: 2023-10-17T20:37:51.000Z (over 1 year ago)
- Last Synced: 2024-10-18T01:59:05.170Z (3 months ago)
- Topics: asciid, asciidoc, asciidoctor, cli, command-line, command-line-tool, documentation-tool, markdown, mediawiki, mediawiki-wikis, pandoc, python, python3, wiki, wikis
- Language: Python
- Homepage:
- Size: 60.5 KB
- Stars: 5
- Watchers: 2
- Forks: 0
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
- Contributing: .github/CONTRIBUTING.md
- License: LICENSE.txt
Awesome Lists containing this project
README
bye_wiki (bw)
=============[![License: BSD 3-Clause License][1]][2]
Say goodbye to your wikis!
Python command-line wrapper to convert MediaWiki pages to other formats with `pandoc`## About
bye_wiki (`bw`) is a Python command-line script to convert MediaWiki pages into other formats like AsciiDoc and Markdown.
This makes it easier to migrate documentation and wiki pages from a MediaWiki server to somewhere else.
Regardless of whatever "somewhere else" means for you, this tool provides a basic conversion for you to work with the information from a new format.
bye_wiki is more or less a fancy wrapper for `requests` and `pandoc`.## How to use
**NOTE**:
You must already have [pandoc][3] installed on your system for this script to work!Once you have `pandoc`, the easiest way to get started with bye_wiki is to install from PyPI:
```sh
pip install --user bye-wiki
```The CLI `--help` menu provides more detailed information about how to use bye_wiki.
Some examples are below:### Example 1
Convert _El Ten Eleven_ Wikipedia page to a Markdown document.
```sh
bw --title "El Ten Eleven" --out ~/ete.md
```### Example 2
Convert _Fedora_Linux_38_Release_Party_Schedule_ from the [Fedora Project][4] MediaWiki to an AsciiDoc document.
```sh
bw --url fedoraproject.org/w --format asciidoc --title "Fedora_Linux_38_Release_Party_Schedule" --out licensing.adoc
```### Example 3
Convert _MusicBrainz Principles_ from the [MusicBrainz][5] MediaWiki to a Markdown document, with the `--markdown-headings=atx` flag excluded from the `pandoc` command:
```sh
bw --url wiki.musicbrainz.org --title MusicBrainz_Principles --out mb-principles.md --atx-off
```_Hint_:
If you are not sure whether you want `--atx-off` or not, you do not.
ATX is the more popular format for Markdown documents, but some writers may prefer to not have ATX-style headers.## How to contribute
See [CONTRIBUTING.md][6].
## Legal
Licensed under [BSD 3-Clause License][2].
[1]: https://img.shields.io/badge/License-BSD%203--Clause-blue.svg
[2]: https://opensource.org/licenses/BSD-3-Clause "BSD-3-Clause License - opensource.org"
[3]: https://pandoc.org/
[4]: https://getfedora.org
[5]: https://musicbrainz.org
[6]: https://github.com/jwflory/bw/blob/main/.github/CONTRIBUTING.md "How to contribute to the project"