From Wikibooks, open books for an open world
Jump to: navigation, search
Bug blank.svg
Git repository of Wikimedia has this file: is a script of the pywikibot framework. It is used to copy images from one wiki to another wiki. If you want to transfer image to Wikimedia Commons you should use


    python [common-arguments] pagename [-interwiki] [-tolang:xx] [-tofamily:yy]


  -interwiki   Look for images in pages found through interwiki links.

  -tolang:xx   Copy the image to the wiki in language xx

  -tofamily:yy Copy the image to a wiki in the family yy

  -file:zz     Upload many files from textfile: [[Image:xx]]

If pagename is an image description page, offers to copy the image to the target site. If it is a normal page, it will offer to copy any of the images used on that page, or if the -interwiki argument is used, any of the images used on a page reachable via interwiki links.

Global arguments available for all bots

arg Description Default
-family:xyz Set the family of the wiki you want to work on, e.g. wikipedia, wiktionary, commons, wikitravel, …. This will override the configuration in settings. parameter: family
-lang:xx Set the language of the wiki you want to work on, overriding the configuration in where xx should be the language code[1]. parameter: mylang
-log Enable the logfile. Logs will be stored in the logs subdirectory. parameter: log ?
-log:xyz Enable the logfile, using xyz as the filename.
-nolog Disable the logfile (if it's enabled by default).
Set the minimum time (in seconds) the bot will wait between saving pages. parameter: putthrottle ?
Make the program output more detailed messages than usual to the standard output about its current work, or progress, while it is proceeding. This may be helpful when debugging or dealing with unusual situations. not selected
  1. Commons uses 'commons' for lang and family; Meta uses 'meta' for both.