A Python robot that edits Wikipedia and interacts with people over IRC https://en.wikipedia.org/wiki/User:EarwigBot
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

README.md 2.8 KiB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869
  1. [EarwigBot](http://en.wikipedia.org/wiki/User:EarwigBot) is a
  2. [Python](http://python.org/) robot that edits
  3. [Wikipedia](http://en.wikipedia.org/) and interacts with people over
  4. [IRC](http://en.wikipedia.org/wiki/Internet_Relay_Chat).
  5. # History
  6. Development began, based on the
  7. [Pywikipedia framework](http://pywikipediabot.sourceforge.net/), in early 2009.
  8. Approval for its fist task, a
  9. [copyright violation detector](http://en.wikipedia.org/wiki/Wikipedia:Bots/Requests_for_approval/EarwigBot_1),
  10. was carried out in May, and the bot has been running consistently ever since
  11. (with the exception of Jan/Feb 2011). It currently handles
  12. [several ongoing tasks](http://en.wikipedia.org/wiki/User:EarwigBot#Tasks),
  13. ranging from statistics generation to category cleanup, and on-demand tasks
  14. such as WikiProject template tagging. Since it started running, the bot has
  15. made over 50,000 edits.
  16. A project to rewrite it from scratch began in early April 2011, thus moving
  17. away from the Pywikipedia framework and allowing for less overall code, better
  18. integration between bot parts, and easier maintenance.
  19. # Installation
  20. This package contains the core `earwigbot`, abstracted enough that it should be
  21. usable and customizable by anyone running a bot on a MediaWiki site. Since it's
  22. component-based, the IRC components can be disabled if desired. IRC commands
  23. and bot tasks specific to
  24. [my instance of EarwigBot](http://en.wikipedia.org/wiki/User:EarwigBot) are
  25. available from the package
  26. [earwigbot-plugins](https://github.com/earwig/earwigbot-plugins).
  27. ## Latest release (v0.1)
  28. EarwigBot is available from the [Python Package Index](http://pypi.python.org),
  29. so you can install the latest release with `pip install earwigbot`
  30. ([get pip](http://pypi.python.org/pypi/pip)).
  31. You can also install it from source directly:
  32. curl -Lo earwigbot.tgz "https://github.com/earwig/earwigbot/tarball/v0.1"
  33. tar -xf earwigbot.tgz
  34. cd earwig-earwigbot-*
  35. python setup.py install # may require root, or use --user switch to install locally
  36. cd ..
  37. rm -r earwigbot.tgz earwig-earwigbot-*
  38. ## Development version
  39. You can install the development version of the bot from `git`, probably on the
  40. `develop` branch which contains (usually) working code. `master` contains the
  41. latest release. EarwigBot uses
  42. [git flow](http://nvie.com/posts/a-successful-git-branching-model/), so you're
  43. free to browse by tags or by new features (`feature/*` branches).
  44. git clone git://github.com/earwig/earwigbot.git earwigbot
  45. cd earwigbot
  46. python setup.py develop # may require root, or use --user switch to install locally
  47. # Setup
  48. It's recommended to run the bot's unit tests before installing. Run
  49. `python -m unittest discover tests` from the project's root directory.
  50. *Note:* some unit tests require an internet connection.
  51. # Customizing
  52. # Hacking