4 * Reassign edits from a user or IP address to another user
7 * @subpackage Maintenance
8 * @author Rob Church <robchur@gmail.com>
11 $options = array( 'force' );
12 require_once( 'commandLine.inc' );
13 require_once( 'reassignEdits.inc' );
15 echo( "Reassign Edits\n\n" );
17 if( @$args[0] && @$args[1] ) {
19 $from = GetUserDetails( $args[0] );
20 $to = GetUserDetails( $args[1] );
23 if( $to['valid'] ||
@$options['force'] ) {
24 ReassignEdits( $from, $to );
26 echo( "User \"$tor\" not found.\n" );
33 /** Show script usage information */
34 function ShowUsage() {
35 echo( "Reassign edits from one user to another.\n\n" );
36 echo( "Usage: php reassignEdits.php <from> <to> [--force]\n\n" );
37 echo( " <from> : Name of the user to assign edits from\n" );
38 echo( " <to> : Name of the user to assign edits to\n" );
39 echo( " --force : Reassign even if the target user doesn't exist\n\n" );