Code to run the Python MediaWiki bot.
jenkins-bot 36d21af5a0 Merge "[IMPR] Improvements for askForHints (3)" 2 weeks ago
docs [doc] Prepare next release 3 months ago
pywikibot Merge "[tests] Use assert_valid_iter_params for Site.blocks()" 2 weeks ago
scripts [IMPR] Improvements for askForHints (3) 2 weeks ago
tests Merge "[cleanup] Skip test classes as a whole" 3 weeks ago
.appveyor.yml Merge "[tests] Remove 32-bit-tests for Python 2.7.4 and 3.4.1" 3 months ago
.codeclimate.yml [tests] Fix similar code checking in codeclimate 4 months ago
.codecov.yml [tests] remove from coverage 5 months ago
.coveragerc Add .coveragerc and codecov.yml 3 years ago
.gitignore Add .vscode in .gitignore 11 months ago
.gitmodules Fix url for .gitmodules 2 years ago
.gitreview Add .gitreview file for git migration 6 years ago
.svnprops update .svnprops 4 years ago
.travis.yml [tests] Update Travis tests configuration 5 months ago
CODE_OF_CONDUCT.rst [doc] use reStructuredText instead of markdown 1 year ago
CONTENT.rst [cleanup] Remove deprecated 7 months ago
CREDITS [bugfix] Remove link to /edithistory from page's edithistory summary. 5 months ago
ChangeLog Update ChangeLog for release 3.0.20170713 2 years ago
Dockerfile Install dev-requirements.txt into Docker image 3 years ago
HISTORY.rst [doc] Update HISTORY.rst 3 weeks ago
LICENSE [doc] Update licence 8 months ago
README-conversion.txt [cleanup] Nothing left to do for a deprecated method 2 months ago
README.rst [doc] Add Python version shield to README.rst 1 year ago
dev-requirements.txt [lib] werkzeug 0.15.5 was published 1 month ago [cleanup] Simpliy generate_family_file.getlangs 5 months ago [PY3] Make Python 2 more Python 3 compatible 2 months ago Merge "[IMPR] Enable global args with script" 1 month ago
requests-requirements.txt [IMPR] Reduce deprecated stuff in requests-requirements.txt 4 months ago
requirements.txt Merge "[bugfix] Drop library part" 5 months ago [tests] Add 'eventstreams' requirement to test_deps 1 month ago
tox.ini Merge "[cleanup] Put fandom defaults into FandomFamily" 1 month ago [doc] remove duplicate spaces inside doc strings 2 years ago Import unicode_literals in 2 years ago


.. image::
:alt: Travis Build Status
.. image::
:alt: AppVeyor Build Status
.. image::
:alt: Code coverage
.. image::
:alt: Maintainability
.. image::
:alt: Python
.. image::
:alt: Pywikibot release


The Pywikibot framework is a Python library that interfaces with the
`MediaWiki API `_
version 1.14 or higher.

Also included are various general function scripts that can be adapted for
different tasks.

For further information about the library excluding scripts see
the full `code documentation `_.

Quick start


git clone
cd core
git submodule update --init
python script_name

Or to install using PyPI (excluding scripts)

pip install -U setuptools
pip install pywikibot

Our `installation
guide `_
has more details for advanced usage.

Basic Usage

If you wish to write your own script it's very easy to get started:


import pywikibot
site = pywikibot.Site('en', 'wikipedia') # The site we want to run our bot on
page = pywikibot.Page(site, 'Wikipedia:Sandbox')
page.text = page.text.replace('foo', 'bar')'Replacing "foo" with "bar"') # Saves the page


For more documentation on pywikibot see our `docs `_.

.. include:: pywikibot/DIRECTORIES.rst

Required external programs

It may require the following programs to function properly:

* `7za`: To extract 7z files

.. include:: HISTORY.rst


Our code is maintained on Wikimedia's `Gerrit installation `_,
`learn `_ how to get

.. include:: CODE_OF_CONDUCT.rst