Code Monkey home page Code Monkey logo

numberof's Introduction

Numberof

by User:GreenC (en.wikipedia.org)

June 2020

MIT License

Files

Numberof is a Wikipedia bot that creates and maintains these files:

..which are pages used by {{Wikipedia rank by size}}, {{NUMBEROF}} and Module:NUMBEROF across many wiki languages and projects.

In addition, the bot creates .tab pages for Module:NumberOf hosted on Ruwiki and a few others. NumberOf is a peer of NUMBEROF, with its own features and requirements. The files are:

Finally, the bot creates forks of the ranking files which are sorted with ties showing equal rank (eg. two wikis can both be ranked #42 if they are tied for that spot). Equal ranking is not supported by Module:NUMBEROF but the data is made available for use such as other templates:

Dependencies

  • GNU Awk 4.1+
  • BotWikiAwk (version Jan 2019 +)
  • A bot User account with bot permissions on Commons

Installation

  1. Install BotWikiAwk following setup instructions.

  2. Add OAuth credentials to wikiget (installed with BotWikiAwk), which is the utility that uploads pages to Commons. See EDITSETUP.

  3. Clone Numberof. For example: git clone https://github.com/greencardamom/Numberof

  4. Edit ~/BotWikiAwk/lib/botwiki.awk

    A. Set local URLs in section #1 and #2

    B. Create a new 'case' entry in section #3, adjust the Home bot path created in step 2:

     case "numberof":                                             # Custom bot paths
     	Home = "/data/project/projectname/numberof/"         # path ends in "/"
     	Agent = UserPage " (ask me about " BotName ")"
     	Engine = 3
     	break
    
  5. Set ~/Numberof/numberof.awk to mode 750, and change the first shebang line to the location of awk.

  6. In numberof.awk in the "BEGIN {" section is a place for an email address for error reports.

Running

  1. See the file toolforge.txt for how to run on Toolforge. Adjust to your local system if not on Toolforge.

numberof's People

Contributors

greencardamom avatar albertvillanova avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.