From 1d749bc52c4fc2f7acb8ba5dfa9ec508e6627fdb Mon Sep 17 00:00:00 2001 From: Aryeh Gregor Date: Mon, 26 Nov 2007 17:58:08 +0000 Subject: [PATCH] Add some stub docs to refreshLinks.php, so at least refreshLinks.php --help doesn't start screwing with your database. $fname -> __METHOD__. --- maintenance/namespaceDupes.php | 3 +-- maintenance/refreshLinks.php | 23 +++++++++++++++++++++++ 2 files changed, 24 insertions(+), 2 deletions(-) diff --git a/maintenance/namespaceDupes.php b/maintenance/namespaceDupes.php index ab889c1f21..323aad59ef 100644 --- a/maintenance/namespaceDupes.php +++ b/maintenance/namespaceDupes.php @@ -205,7 +205,6 @@ class NamespaceConflictChecker { } function resolveConflictOn( $row, $table ) { - $fname = 'NamespaceConflictChecker::resolveConflictOn'; echo "... resolving on $table... "; $newTitle = Title::makeTitleSafe( $row->namespace, $row->title ); $this->db->update( $table, @@ -217,7 +216,7 @@ class NamespaceConflictChecker { "{$table}_namespace" => 0, "{$table}_title" => $row->oldtitle, ), - $fname ); + __METHOD__ ); echo "ok.\n"; return true; } diff --git a/maintenance/refreshLinks.php b/maintenance/refreshLinks.php index 34ca53c510..923379e870 100644 --- a/maintenance/refreshLinks.php +++ b/maintenance/refreshLinks.php @@ -6,9 +6,32 @@ /** */ $optionsWithArgs = array( 'm', 'e' ); + require_once( "commandLine.inc" ); require_once( "refreshLinks.inc" ); +if( isset( $options['help'] ) ) { + echo << : Specifies max replication lag? Does it abort or wait if this + is exceeded? + start : First page id to refresh? Doesn't work with --dfn-only set? + -e : Last page id to refresh? + +This uses wfGetDB() to get the database, it seems not to accept a database ar- +gument on the command line. So I don't know if you can use it for non-default +configuration. + +Todo: Real documentation. + +TEXT; + exit(0); +} + error_reporting( E_ALL & (~E_NOTICE) ); if ( !$options['dfn-only'] ) { -- 2.20.1