Uporabnik:Mihas-bot/Indeksiranje
Mihas-bot Indeksiranje je storitev, ki generira tabelo s preglednimi podatki o temah v arhivih daljših pogovornih strani, kot je npr. Wikipedija:Pod lipo. Upravlja, ga Mihael Simonič, originalno kodo pa sta za angleško Wikipedijo napisala HighInBC in Krellis. Vsak izmed uporabnikov Wikipedije lahko zaprosi za storitev po naslednjih navodilih.
Uredi
Ta članek je treba prevesti v slovenščino. |
To use this service you need archives, a destination page, and a page for the request.
- First create a destination page (the one you want the index to be written to) and place the following text on this page:
<!-- HBC Archive Indexerbot can blank this -->
- This will not be visible, as it is contained in HTML comment tags; this gives the bot permission to write to the page.
- On the root page of the archives you want indexed, usually the talk page itself, place the following code:
{{User:HBC Archive Indexerbot/OptIn|target=<target>|mask=<mask>|leading_zeros=<zeros>|indexhere=<indexhere>|template=<template location>}}
<target>
is your destination page (created in step 1)<mask>
is used to describe how to find your archives, see below for details. You may specify multiple masks by specifying themask=<mask>
parameter multiple times. Pages matching all of the masks will be combined together for the final index.<zeros>
is the number of leading 0's in your archive title, "Archive 01" would be 1 leading zero, "Archive 1" is 0 leading zeros.<indexhere>
should be yes or no. If yes, it will index the root talk page the request is on as well as the archive pages.
<template location>
is the name of a wiki page containing an archive index template. The template syntax is described below. This parameter is optional, and if left out or left blank, the default template will be applied.
- Note: Relative paths may be specified, and will be assumed to be relative to the page on which the OptIn code is placed. If you are unsure, full paths are always best.
- Wait; the next time the bot runs it should write your report.
MaskUredi
Your mask is simply the path of your archives with the numbers replaced with <#>
.
Example:
User talk:HighInBC/Archive <#>
would cover User talk:HighInBC/Archive 1
through the last archive.
If your archive has leading zeros, then set the leading_zeros parameter to the amount of leading zeros you have.
If your archives are named using dates rather than numbers, or by topic, you can specify multiple mask parameters in the template, each of which will be read in turn. If there's no incrementing number, simply do not include the <#>
in the mask, and it will be used as an individual page name instead.
PredlogaUredi
Predloge so definirane kot serija nevidnih HTML komentarjev, oblikujejo pa se z standardnim wikitextom. Za primer glej privzeto predlogo Vsak razdelek se začne z nevidnim HTML komentarjem, ki vsebuje samo ime razdelka (glej spodnjo tabelo). Razdeček se zaključi začetkom naslednjega.
Razdelki
Naziv razdelka
Opis
LEAD
Uvodno besedilo, ki bo prikazano na vrhu strani s kazalom tem.
HEADER
A header for the index, placed after the bot's description of how the index was created, but before any rows of data are output. Typically used to begin a table, create column headings, etc.
ROW
The format of an actual row of data. There are a number of variables available in the row:
%%topic%%
- The topic from the archives, as pulled from the archive heading.
%%replies%%
- The estimated number of replies contained within that section of the archive.
%%link%%
- A link directly to the appropriate section in the appropriate archive for this topic.
%%first%%
- Timestamp of first comment in the topic (YYYY-MM-DD HH:MM:SS format). Available in epoch seconds as %%firstepoch%%
.
%%last%%
- Timestamp of last comment in the topic (YYYY-MM-DD HH:MM:SS format). Available in epoch seconds as %%lastepoch%%
.
%%duration%%
- Duration of the topic (difference between first and last, in normalized text format). Available in raw seconds as %%durationsecs%%
.
This section is required (and this is the only section required in a template, all others are optional).
ALTROW
The format of an alternating row. If provided, this section will be used instead of the "Row" section for every other row of data, starting with the second. It is generally used to alternate row colors within a table. The same variables described in "Row" above are available.
FOOTER
A footer, output immediately after the last row of data. Generally used to close a table, if one was started in the header.
TAIL
A final section below the footer, for any comments, bottom-of-page navigation, categories, etc.
END
Indicates that the template definition is over, no more parsing will take place.
ScheduleUredi
The bot is currently scheduled to run twice per day, at 11:23 and 23:23 UTC. It may run at additional times beyond those, and may miss some scheduled runs while it is under continued development/bugfixing.
CaveatsUredi
- Very long sets of archives such as Wikipedia:Administrators' noticeboard/IncidentArchive<#> will not archive due to timeout errors and maximum page size.
- When using sortable table for results, the
%%duration%%
will sort alphabetically, which is probably unfavourable behavior. To work around this, use invisible %%durationsec%%
variable like this: <span style="display: none;">%%durationsecs%%</span> %%duration%%
PovezaveUredi