Difference between revisions of "Template:Infobox Wikipedia bot"

From blackwiki
Jump to navigation Jump to search
imported>Rjanag
(making caption optional)
imported>DemonDays64
(Undid revision 929935351 by DemonDays64 (talk))
 
(51 intermediate revisions by 21 users not shown)
Line 1: Line 1:
{| class="infobox" style="width:21em; font-size: 90%; text-align: left;"
+
<includeonly>{{Infobox
! colspan="2" style="text-align: center; font-size: 130%;" | {{{Bot name}}} [[File:Crystal Clear action run.svg|24px|This user is a bot.]]
+
| title    = {{{Bot name}}}
|-
+
| above    = {{#if: {{{isbot|}}}|{{#switch:{{{isbot|}}}|no|No=|#default=This user is a bot}}|This user is a bot}}
| colspan="2" style="text-align: center; font size: 95%;" | ([[{{TALKSPACE}}:{{{Bot name}}}|talk]] · [[Special:Contributions/{{{Bot name}}}|contribs]])
+
| subheader = ([[{{{talkpagespace|{{TALKSPACE}}}}}:{{{username|{{{Bot name}}}}}}|talk]] · [[Special:Contributions/{{{username|{{{Bot name}}}}}}|contribs]])
{{#if:{{{logo<includeonly>|</includeonly>}}}|
+
| image1    = {{#invoke:InfoboxImage|InfoboxImage|image={{{logo|}}}}}
<tr><td colspan="2" style="text-align: center;">{{{logo}}}</td></tr>
+
| image2    = {{#invoke:InfoboxImage|InfoboxImage|image={{{image|}}}}}
}}{{#if:{{{image<includeonly>|</includeonly>}}}|
+
| caption2  = {{{caption|}}}
<tr><td colspan="2" style="text-align: center;">{{{image}}}<br />{{#if:{{{caption|}}}|{{{caption}}}}}</td></tr>
+
 
}}{{#if:{{{operator<includeonly>|</includeonly>}}}|
+
| label1    = Status
<tr><th>Operator:</th><td>{{{operator}}}</td></tr>
+
| data1    = {{{status|{{#switch:{{lc:{{{active|}}}}}|true|yes='''<span style="color:#008000">Active</span>'''|false|no='''<span style="color:#800000">Inactive</span>'''|#default=}}}}}
}}{{#if:{{{author<includeonly>|</includeonly>}}}|
+
| label2    = Operator
<tr><th>Author</th><td>{{{author}}}</td></tr>
+
| data2    = {{{operator|}}}
}}{{#if:{{{approval<includeonly>|</includeonly>}}}|
+
| label3    = Author
<tr><th>[[Wikipedia:Bots/Requests for approval|Approved]]?</th><td>{{#switch: {{{approval|}}}|yes|Yes=[[Wikipedia:Bots/Requests for approval/{{PAGENAME}}|{{{approval}}}]]|#default={{{approval}}}}}</td></tr>
+
| data3    = {{{author|}}}
}}{{#if:{{{flag<includeonly>|</includeonly>}}}|
+
| label4    = [[Wikipedia:Bots/Requests for approval|Approved]]?
<tr><th>[[Wikipedia:User_access_levels#Bots|Flagged?]]</th><td>{{{flag}}}</td></tr>
+
| data4    = {{#switch:{{{approval|}}}|yes|Yes=[[Wikipedia:Bots/Requests for approval/{{#if:{{{brfa|}}}|{{{brfa|}}}|{{PAGENAME}}}}|{{{approval|}}}]]|yesnolink=Yes|#default={{{approval|}}}}}
}}{{#if:{{{tasks<includeonly>|</includeonly>}}}|
+
| label5    = [[Wikipedia:User_access_levels#Bots|Flagged]]?
<tr><th>[[Wikipedia:Bot requests|Task/s]]:</th><td>{{{tasks}}}</td></tr>
+
| data5    = {{{flag|}}}
}}{{#if:{{{edit rate<includeonly>|</includeonly>}}}|
+
| label6    = Task(s)
<tr><th>Edit rate:</th><td>{{{edit rate}}}</td></tr>
+
| data6    = {{{tasks|}}}
}}{{#if:{{{period<includeonly>|</includeonly>}}}|
+
| label7    = Edit rate
<tr><th>Edit period/s:</th><td>{{{period}}}</td></tr>
+
| data7    = {{{edit rate|}}}
}}{{#if:{{{process<includeonly>|</includeonly>}}}|
+
| label8    = Edit period(s)
<tr><th>Automatic or manual?</th><td>{{{process}}}</td></tr>
+
| data8    = {{{period|}}}
}}{{#if:{{{language<includeonly>|</includeonly>}}}|
+
| label9    = Automatic or manual?
<tr><th>[[Programming language]]/s:</th><td>{{{language}}}</td></tr>
+
| data9    = {{{process|}}}
}}{{#if:{{{Excl. comp.<includeonly>|</includeonly>}}}|
+
| label10    = [[Programming language]](s)
<tr><th>Exclusion compliant?</th><td>{{{Excl.Comp.|{{ #if: yes| Yes [[Category:Wikipedia bots which are exclusion compliant|{{PAGENAME}}]] }}}}}</td></tr>
+
| data10    = {{{language|}}}
}}{{#if:{{{source<includeonly>|</includeonly>}}}|
+
| label11  = [[:Category:Wikipedia bots which are exclusion compliant|Exclusion compliant]]?
<tr><th>Source code published?</th><td>{{{source}}} {{#ifeq: {{{source}}} | yes | [[Category:Wikipedia bots with {{#switch:{{{lang_cat|{{{language}}}}}}
+
| data11    = {{#if:{{yesno|{{{Excl. comp.|}}}|def=}}|Yes{{#ifeq:{{{nocat}}}|yes||[[Category:Wikipedia bots which are exclusion compliant|{{PAGENAME}}]]}}|No}}
|C++
+
| label12  = Source code published?
|Python
+
| data12    = {{{source|}}} {{#switch:{{lc:{{{source|}}}}}|no|=|#default={{#ifeq:{{{nocat}}}|yes|| [[Category:Wikipedia bots with {{#switch:{{lc:{{delink|{{#if:{{{lang_cat|}}}|{{{lang_cat}}}|{{{language|}}}}}}}}}
|Perl
+
| wp:awb       
|Java
+
| autowikibrowser
|PHP
+
| awb        = AutoWikiBrowser
|C Sharp=  {{{lang_cat|{{{language}}}}}}  
+
| ruby        = Ruby
|pywikipedia= Python
+
| pywikipedia
|#default= }} source code published|{{PAGENAME}}]] }}
+
| pywikibot
{{#ifeq: {{{source}}} | Yes | [[Category:Wikipedia bots with {{#switch:{{{lang_cat|{{{language}}}}}}
+
| pywiki
|C++
+
| python      = Python
|Python
+
| perl        = Perl
|Perl
+
| java        = Java
|Java
+
| javascript  = Javascript
|PHP
+
| php        = PHP
|C Sharp= {{{lang_cat|{{{language}}}}}}
+
| c#
|pywikipedia= Python
+
| c sharp    = C Sharp
|#default= }} source code published|{{PAGENAME}}]] }}</td></tr>
+
| #default   =  
}}{{#if:{{{shutoff<includeonly>|</includeonly>}}}|
+
}} source code published|{{PAGENAME}}]]}}}}
<tr><th>Emergency shutoff-compliant?</th><td>{{{shutoff|{{{shutoff_compliant|{{#if:yes|Yes }}}}}}}}</td></tr>
+
| label13  = Emergency shutoff-compliant?
}}
+
| data13    = {{{shutoff|{{{shutoff_compliant|{{#if:yes|Yes}}}}}}}}
{{#if:{{{other<includeonly>|</includeonly>}}}|
+
| label14  = Other information
<tr><th>Other information:</th><td>{{{other|}}}</td></tr>
+
| data14    = {{{other|}}}
}}
+
 
|}<noinclude>
+
}}{{#ifeq:{{{nocat}}}|yes||{{#switch:{{lc:{{{active|}}}}}|true|yes=[[Category:Active Wikipedia bots]]|false|no=[[Category:Inactive Wikipedia bots]]}}}}</includeonly><noinclude>{{Documentation}}<!-- PLEASE ADD CATEGORIES AND INTERWIKIS TO THE /doc SUBPAGE, THANKS. --></noinclude>
{{Documentation}}
 
<!-- PLEASE ADD CATEGORIES AND INTERWIKIS TO THE /doc SUBPAGE, THANKS -->
 
</noinclude>
 

Latest revision as of 05:23, 9 December 2019

Template documentation[view] [edit] [history] [purge]

Infobox

The complete infobox:

{{Infobox bot
| Bot name     = 
| image        =
| caption      = 
| status       =
| operator     = 
| author       = 
| approval     = 
| flag         = 
| tasks        = 
| edit rate    = 
| process      = 
| language     = 
| period       =
| Excl. comp.  =
| source       =
| lang_cat     =
| shutoff      =
| other        =
| nocat        =
| brfa         =
| active       =
}}

Values for lang_cat are AWB, C Sharp, Java, Javascript, Perl, PHP, Python, and Ruby.

Status

Setting |active=yes will set the "Status" field to Active and, unless |nocat=yes, place the page into Category:Active Wikipedia bots. Setting |active=no will set the "Status" field to Inactive and, unless |nocat=yes, place the page into Category:Inactive Wikipedia bots. Setting the |status= parameter to any value will override the automatic value in the status field.

If the bot uses a status or automatic shutoff page, you can use it to automatically categorize the bot. If the status page consists only the word "true"/"false" (or "yes"/"no"), you can use:

active={{lc:{{NAME OF STATUS PAGE}}}}

If it uses something other than "true"/"false" or "yes"/"no", but there are still only one possible contents of the status page when the bot is running, use:

active={{#ifeq:{{lc:{{NAME OF STATUS PAGE}}}}|LOWER CASE TEXT IF BOT IS ACTIVE|yes|no}}

If your bot has multiple lines on the status page for multiple bot tasks, and you want to display as active if any of them are running (indicated by "true" in this example), use:

active={{#iferror:{{#invoke:String|match|s={{NAME OF STATUS PAGE}}|pattern=true}}|no|yes}}

Example

SkyBot 1
This user is a bot
(talk · contribs)
SkyBot 1
SkyBot 1 at top-speed
OperatorAnonymous Dissident (t)
Approved?Not yet
Flagged?No
Task(s)(Will) Work at WP:CFD/W, Wikiproject tagging.
Edit rate(Proposed) 10 per minute
Edit period(s)Periodically
Automatic or manual?Automatic
Programming language(s)Works through AWB
Exclusion compliant?Yes
Source code published?no
Emergency shutoff-compliant?Yes
Other informationSkyBot 1 may later be assigned the task of delivering newsletters.
[[Category:Infobox templates|Template:Remove first word]]
{{Infobox bot
|Bot name = SkyBot 1
|image = [[File:F-105 Thunderchief underside.jpg|300px|SkyBot 1]]
|caption = '''SkyBot 1 at top-speed'''
|operator = [[user:Anonymous Dissident|Anonymous Dissident]] [[User talk:Anonymous Dissident|(t)]]
|approval = Not yet
|flag = No
|tasks = (Will) Work at [[WP:CFD/W]], Wikiproject tagging.
|edit rate = (Proposed) 10 per minute
|period = Periodically
|process = Automatic
|language = Works through [[WP:AWB|AWB]]
|Excl. comp. = yes
|source = no
|other = SkyBot 1 may later be assigned the task of delivering newsletters.
}}