帮助:扩展:大量删除

This page is a translated version of the page Help:Extension:Nuke and the translation is 4% complete.

The extension Nuke is useful to mass-delete unwanted pages (spam, vandalism…). Before deletion, pages can be filtered by editor, title, and/or namespace, and individual pages are listed by actual deletion.

Note that, on the contrary to the “rollback” operation (also called “revert”), Nuke deletes entire pages with their history. If you want to delete individual contributions but keep the pages, you have to use the “rollback” feature (by default granted to administrators (sysops)).

See the main page of the extension for help about installation and configuration.

Go to the page Special:Nuke or search 大量删除 in the list of special pages. You must have the right nuke (granted to administrators (sysops) by default, see User rights and groups). Also, there is a link “大量删除” on the top of the page listing the contributions of a user or IP address (Special:Contributions).

First screen, with the various criteria to select pages.

On the first screen, before deleting pages, you have to select the pages according to certain criteria:

  • User name or IP address;
  • Page name, or pattern of page names (see below for the syntax);
  • A specific namespace or all namespaces

You can enter one or multiple criteria. If you enter multiple criteria, pages matching all the criteria will be selected. If you enter no criteria, all recent pages will be selected.

Second screen, listing individual pages

After clicking on “列举页面”, you get a second screen where the selection is displayed and you can select or unselect individual pages. You can modify the reason displayed in the logs, and then click on “删除所选”.

A confirmation of the actual deletions is then displayed. All deletions are logged in the general deletion log Special:Log/delete.

Pattern of page names

Wildcards can be used in the field “页面名称的SQL LIKE模式(例如%):”, specifically SQL LIKE wildcards:

  • _ (underscore) means exactly one character;
  • % (percent sign) means zero or any number of characters.

Page names must be written in the database-encoded form, corresponding to the page name in the URL (where underscore are used for spaces, and a capital letter is used as first letter if the namespace is case-insensitive).

Three characters must be encoded specifically:

  • the space “ ” must be encoded as \_ (because an underscore alone is the wildcard “one character”)
  • the percent sign “%” must be encoded as \%
  • the backslash sign “\” must be encoded as \\

Frequently asked questions

Does Nuke free disk space?

No. The pages are deleted like the classical operation “delete” in MediaWiki: they are removed from public view, but administrators can still view them and restore them. Other extensions like DeletePagesForGood can permanently delete pages.

Can I mass-delete pages according to a manual list?

Currently no. There is another extension, DeleteBatch, which has this feature. The task T68447 was opened to request this feature in Nuke.

Why are some pages meeting the criteria not listed?

The search is restricted to recent modifications, where "recent" is given by the configuration parameter $wgRCMaxAge (by default 90 days). The task T33858 requests the feature of searching all pages, not just recent pages.