扩展:用户合并

This page is a translated version of the page Extension:UserMerge and the translation is 64% complete.
Other languages:
Deutsch • ‎English • ‎español • ‎français • ‎português • ‎português do Brasil • ‎中文 • ‎日本語 • ‎한국어
MediaWiki扩展手册
OOjs UI icon advanced.svg
UserMerge
发布状态: 稳定版
UserMergeScreenshot.png
实现 特殊页面 , 用戶識別
描述 Merges references from one user to another user in the Wiki database - can also delete old users following merge
作者 Tim Laqua, Thomas Gries, Siebrand Mazeland
最新版本 1.10.1 (2019-05-31)
兼容性方针 主线(master)
MediaWiki 1.34+
PHP 7.0+
数据庫更新
许可协议 GNU通用公眾授權條款2.0或更新版本
下载
$wgUserMergeProtectedGroups
usermerge
翻译UserMerge扩展如果在translatewiki.net可用
检查使用和版本矩阵。
Vagrant角色 usermerge
问题 开放的工作 · 报告错误

用户合并(UserMerge)扩展允许有“usermerge”权限的wiki用户(默认为行政员)合并一个Wiki用户账户至另一个Wiki用户账户。

该扩展允许

  • 合并(将贡献,文本,监视列表,第一个帐户A的编辑计数引用到第二个帐户B)
  • 合并后删除第一个帐户A(选项框)

限制

  • 您必须先将用户A合并到B才能删除用户A
  • 您不能将自己的帐户(登录用户)合并到其他用户中

額外

  • if you omit the "New User" field, then the extension auto-populates the New User as "Anonymous" (user_id 0), and ask you to confirm a merge to Anonymous. This is used for user deletion: you first empty (merge to user 0) contributions of a user A, and then delete the user A.
    • If your version of the extension complains about an empty "New User" field you can fill in  "Anonymous"
  • the extension creates a User Merge log and logs all User Merge extension activity.[1]

安装

  • 如果使用Vagrant ,请通过vagrant roles enable usermerge --provision安装
手动安装
  • 下载文件,并将其放置在您extensions/文件夹中的UserMerge目录内。
  • 将下列代码放置在您的LocalSettings.php的底部:
    wfLoadExtension( 'UserMerge' );
    // By default nobody can use this function, enable for bureaucrat?
    $wgGroupPermissions['bureaucrat']['usermerge'] = true;
    
    // 可选:默认为 array( 'sysop' )
    $wgUserMergeProtectedGroups = array( 'groupname' );
    
  •   完成 – 在您的wiki上导航至Special:Version,以验证扩展已成功安装。

致使用MediaWiki 1.25或更早版本的用户:

上面的说明介绍的是安装此扩展的新方法,它使用wfLoadExtension()。 如果您需要在早期版本(MediaWiki 1.25和更早版本)中安装此扩展,而不是wfLoadExtension( 'UserMerge' );,您需要使用:

require_once "$IP/extensions/UserMerge/UserMerge.php";

Historical

The change to group-based merge protection ($wgUserMergeProtectedGroups) in v1.5, r30872.
The addition of the 'usermerge' permission in v1.2 - this must be explicitly granted as shown above.

用法

  • 请遵循安装说明
  • a new Special Page Special:UserMerge with the title Merge and Delete Users is created
  • 可以定义不可合并的用户(示例):
# Allow all users to be merged (by default, the 'sysop' group is unmergeable)
$wgUserMergeProtectedGroups = array();

# Disallow merging of the users in the 'sysop' or 'awesomeusers' groups
$wgUserMergeProtectedGroups = array( 'sysop', 'awesomeusers' );

You can use RevisionDelete extension installed by default to replace the UserMerge logs information with neutral information.

Active RevisionDelete in LocalSettings.php with :

$wgGroupPermissions['sysop']['deletelogentry'] = true;
$wgGroupPermissions['sysop']['deleterevision'] = true;

Then, from Special:Log/usermerge, you can check and disable the logs content resulting from modifications made by UserMerge with simple check box.

A better approach would be with CleanMediawiki.sh script for delete massive spam user and all logs : https://github.com/ZerooCool/cleanmediawiki

已知的问题

参考资料

  1. since version 1.2

参见