User:Animum/EasyBlock

EasyBlock (source) is one of my scripts that aids admins who often do routine blocks, such as those for vandalism, username violations, or sockpuppeteering.

This tool will display a "block" tab, which, when the mouse hovers over it, will display a list of block options on the following pages/namespaces (see below for display options, and please read how the script detects usernames):
 * User: or User_talk: namespaces
 * Special:Block
 * Special:BlockList, after unblocking a user
 * Special:Contributions
 * Any diff screen

If  (see below) is not set to false, it will also automatically warn (depending on the type of block done, it may also tag) users after they've been blocked.

Installation
To install this application, add the following code to your monobook exactly as it appears when viewing this page, and bypass your cache:

ebPrefs
EasyBlock has eight available preferences:

(Note: For the purposes of the table below, "edits" is defined as "the warnings or notifications the script will post when automatically warning a user.")

To set one or more of the preferences to a value, use the  pattern, which Twinkle also uses. Assume that I want to set  to ,   to  , and to make the tab hidden on Special:Block. I would need to add the following to my monobook:
 * Note: The last  entry should not have a comma after it.

If you want another configurable option or need to report a bug, you can leave me a message, send me an e-mail, or contact me on IRC (if I so happen to be there). The preferred method, however, is the first one because others can act on the requests if I can't.

User detection methods (very important)
The following is the methodology this script uses to gather the username of the user to block:
 * On Special:Block, the name of the user who would be blocked per the normal means otherwise;
 * On User: or User_talk: pages, the name of the corresponding user, except for diffs, which will take the name of the user who made that specific edit;
 * On diffs of any page, the name of the user who made the edit will override any other data the script would normally collect. For instance, the username would be "Animum" on my talk page except when viewing a diff, which will take the name of the user who made the edit (in this case, Aitias);
 * On Special:Contributions, the name of the user whose contributions are being queried; and
 * On Special:BlockList, the name of the user who was just unblocked (the tab will only appear after a successful unblock).

A note about sockpuppet blocks
When using this script, please only use the "confirmedsock" option if there is specific CheckUser evidence; please use the "suspectedsock" option for all other cases.