Template:Autoarchive resolved section

From Wikisource
Jump to navigation Jump to search
Template documentation[view] [edit] [history] [purge]

Usage[edit]

This type of archiving is done by SpBot (not by ArchiverBot). It requires the use of either {{section resolved}} or the timeout parameter of this template (normal archiving).

It does not matter where the template "Section resolved" is placed within the section. It will always refers to the last/previous heading of the section to be archived.

To quickly use a standard setup to archive your user talk page, see #Example.

Template parameters[edit]

Template parameters

ParameterDescriptionTypeStatus
Ageage

Parameter <code>age</code> defines the required age of the the template ''Section resolved'' in days. After this amount of days the section will be archived.

Numberrequired
Archivearchive

You can use variables in your <code>archive</code>-parameter as [[#.22Archive.22_parameter_variables|listed below]]. Example: <code>archive=Talk:Some page/Archives/((year))/((month:short))</code> (just an example, not really used there)

Unbalanced wikitextrequired
Overviewoverview

The parameter <code>overview</code> can be used to display a link to the location of the archive page. Example code: <code><nowiki>overview=[[/Archive]]</nowiki></code> Results in an archive overview link at ''<nowiki><code>[[/Archive]]</nowiki></code>''. An alternative to this parameter is the use of [[Template:Archive box]].

Page nameoptional
Latest archivelatest archive

The parameter <code>latest archive</code> can be used to display a link to the current archive. Example code: <code><nowiki>latest archive=[[Wikisource:Forum/Archiv/2016/October]]</nowiki></code> Results in: The latest archive is located under '''[[Commons:Forum/Archiv/2016/October]]'''.

Default
Page nameoptional
Showshow

The parameter <code>show</code> defines if the template should display anything or not: <code>show=yes</code> or <code>show=no</code>. This parameter can be used if the template is used on a page which has an own intro explaining the archiving parameters.

Default
yes
Stringoptional
Levellevel

Parameter <code>level</code> defines which heading level should be archived. Deeper heading levels are treated as part of the specified level.

Default
2
Numberoptional
Timecomparetimecompare

This parameter specifies which timestamp should be used for distribution into the archives. In the parameter <code>archive</code> you can use variables referring to the date.

<code>timecompare</code> defines which timestamp is used for this parameter <code>archive</code>.
* <code>timecompare = resolved</code>: Timestamp given by {{Tl|Section resolved}}
* Any other value or empty: the oldest timestamp of the whole section

Default
Unknownoptional
Timeouttimeout

Specifies the number of days have to pass by to consider a section as 'resolved' automatically, even if no {{Tl|Section resolved}} template was set. Archiving will be proceeded if the specified period of time (''timeout'') has passed since the last comment. The template {{Tl|DNAU}} is supported.

Default
0
Numberoptional

"Archive" parameter variables[edit]

You can use the following variables in your archive-parameter:

variable meaning
((year)) year e.g. 2020
((month:long)) full monthname e.g. February
((month:short)) short monthname e.g. Feb
((month:##)) month as two digits e.g. 02
((week)) week date as a number e.g. 15, 4 (per ISO 8601/DIN 1355-1)
((week:##)) week date as a two digits e.g. 15, 04 (per ISO 8601/DIN 1355-1)
((day:##)) day of month as two digits e.g. 31, 07
((quarter)) quarter e.g. 3
((quarter:##)) quarter as two digits e.g. 03
((quarter:i)) quarter as lowercase Roman numerals e.g. iii
((quarter:I)) quarter as uppercase Roman numerals e.g. III
((half-year)) half-year e.g. 2
((half-year:i)) half-year as lowercase Roman numeral e.g. ii
((half-year:I)) half-year as uppercase Roman numeral e.g. II
((FULLPAGENAME)) The namespace + page name of the current page. Same as {{FULLPAGENAME}}, but with normal brackets. Use this instead of hard coding your page name.

Example: archive=((FULLPAGENAME))/Archive/((year))((month:short))

Example[edit]

The following example is derived from the archiving setup of commons:Commons:Village pump. All marked/tagged sections with level 2 (that is ==) will be archived one day after placement of Template:Section resolved. The archives are at commons:Special:PrefixIndex/Commons:Village pump. The archiving will be done to /Archive/2017/January if the first comment in this section was made in January.

{{Autoarchive resolved section
 |age=1
 |archive=((FULLPAGENAME))/Archive/((year))/((month:##))
 |overview=[[Special:PrefixIndex/{{subst:FULLPAGENAME}}/Archive|Archive]]
}}

That will look like this:

Filing cabinet icon.svg
SpBot archives all sections tagged with {{section resolved|1=~~~~}} after 1 day. For the archive overview, see archive.

Full template[edit]

{{autoarchive resolved section
 | age            = 
 | archive        = 
 | overview       = 
 | latest archive = 
 | show           = 
 | level          = 
 | timecompare    = 
 | timeout        = 
}}

Signature format[edit]

The date and time part of the signature are important for recognition of the timestamp. The default format specified by MediaWiki is sufficient (11:55, 29. Nov 2020 (UTC)). It corresponds to the following structure:

{{subst:LOCALTIME}}, {{subst:LOCALDAY}}. {{subst:LOCALMONTHABBREV}} {{subst:LOCALYEAR}} (UTC)

Other formats are not supported.

Error lists[edit]

Talk pages containing errors in their main templates or {{Section resolved}} are shown in the following lists and on the corresponding talk page.

Info