Pybot Wiki
Register
mNo edit summary
mNo edit summary
Line 17: Line 17:
 
When using this script to add things like templates or categories to large groups of pages, it is generally best to add them to the bottom of the page. You can do this by using the following command:
 
When using this script to add things like templates or categories to large groups of pages, it is generally best to add them to the bottom of the page. You can do this by using the following command:
   
:''add_text.py -page:"" (if adding to a specific page) -cat:"" (if adding to a specific category)
+
:''<code>python add_text.py -page:"" (if adding to a specific page) -cat:"" (if adding to a specific category)</code>
   
 
When using this script to add things to the top of a page, you will instead use this command:
 
When using this script to add things to the top of a page, you will instead use this command:
   
:''add_text.py -page:"" (if adding to a specific page) -cat:"" (if adding to a specific category) -up (this is what adds the text to the top of the page)
+
:''<code>python add_text.py -page:"" (if adding to a specific page) -cat:"" (if adding to a specific category) -up (this is what adds the text to the top of the page)</code>
   
 
== Full list of available parameters ==
 
== Full list of available parameters ==

Revision as of 02:00, 7 December 2013

This page describes a script. In general, it refers to the script in its current form, but pywikpedia coders tend only to add functions, not take them away. Chances are that you'll be able to use most of the information on the page, regardless of the age of your installation.

add_text.py
Creator: Filnik
Code location: wikimedia repository
What it does: Adds a string of text to a page.
Complexity: Basic

Add_text.py is a simple script that can add a string of text to either the top or bottom of a page. This can be used to do things like adding a template or another category to a large group of pages.

Command line examples

When using this script to add things like templates or categories to large groups of pages, it is generally best to add them to the bottom of the page. You can do this by using the following command:

python add_text.py -page:"" (if adding to a specific page) -cat:"" (if adding to a specific category)

When using this script to add things to the top of a page, you will instead use this command:

python add_text.py -page:"" (if adding to a specific page) -cat:"" (if adding to a specific category) -up (this is what adds the text to the top of the page)

Full list of available parameters

  • -page
  • -text
  • -except
  • -excepturl
  • -newimages
  • -untagged
  • -always
  • -up
  • -file
  • -summary