3 * @addtogroup Maintenance
7 $optionsWithArgs = array( 'm', 'e' );
9 require_once( "commandLine.inc" );
10 require_once( "refreshLinks.inc" );
12 if( isset( $options['help'] ) ) {
15 php refreshLinks.php --help
16 php refreshLinks.php [<start>] [-e <end>] [-m <maxlag>] [--dfn-only]
17 [--new-only] [--redirects-only]
18 php refreshLinks.php [<start>] [-e <end>] [-m <maxlag>] --old-redirects-only
20 --help : This help message
21 --dfn-only : Delete links from nonexistent articles only
22 --new-only : Only affect articles with just a single edit
23 --redirects-only : Only fix redirects, not all links
24 --old-redirects-only : Only fix redirects with no redirect table entry
25 -m <number> : Maximum replication lag
26 <start> : First page id to refresh
27 -e <number> : Last page id to refresh
33 error_reporting( E_ALL
& (~E_NOTICE
) );
35 if ( !$options['dfn-only'] ) {
36 if ( isset( $args[0] ) ) {
37 $start = (int)$args[0];
42 refreshLinks( $start, $options['new-only'], $options['m'], $options['e'], $options['redirects-only'], $options['old-redirects-only'] );
44 // this bit's bad for replication: disabling temporarily
46 //deleteLinksFromNonexistent();
48 if ( $options['globals'] ) {