Fix up paths so you can call these scripts from base dir
authorBrion Vibber <brion@users.mediawiki.org>
Wed, 24 Jan 2007 01:28:50 +0000 (01:28 +0000)
committerBrion Vibber <brion@users.mediawiki.org>
Wed, 24 Jan 2007 01:28:50 +0000 (01:28 +0000)
Also fixed an 'old' table reference which should now be 'text' ...

maintenance/storage/compressOld.php
maintenance/storage/dumpRev.php
maintenance/storage/moveToExternal.php
maintenance/storage/resolveStubs.php

index 90f4947..87aebb7 100644 (file)
@@ -31,7 +31,7 @@
  */
 
 $optionsWithArgs = array( 't', 'c', 's', 'f', 'h', 'extdb', 'endid', 'e' );
-require_once( "../commandLine.inc" );
+require_once( dirname(__FILE__) . '/../commandLine.inc' );
 require_once( "compressOld.inc" );
 
 if( !function_exists( "gzdeflate" ) ) {
index a082edc..d35af38 100644 (file)
@@ -1,8 +1,9 @@
 <?php
 
-require_once( 'commandLine.inc' );
+require_once( dirname(__FILE__) . '/../commandLine.inc' );
+
 $dbr = wfGetDB( DB_SLAVE );
-$row = $dbr->selectRow( 'old', array( 'old_flags', 'old_text' ), array( 'old_id' => $args[0] ) );
+$row = $dbr->selectRow( 'text', array( 'old_flags', 'old_text' ), array( 'old_id' => $args[0] ) );
 $obj = unserialize( $row->old_text );
 
 if ( get_class( $obj ) == 'concatenatedgziphistoryblob' ) {
index 40ac84d..6d3ebfc 100644 (file)
@@ -5,7 +5,7 @@ define( 'REPORTING_INTERVAL', 1 );
 if ( !defined( 'MEDIAWIKI' ) ) {
        $optionsWithArgs = array( 'm', 's' );
 
-       require_once( '../commandLine.inc' );
+       require_once( dirname(__FILE__) . '/../commandLine.inc' );
        require_once( 'ExternalStoreDB.php' );
        require_once( 'resolveStubs.php' );
 
index 973b7b0..6836ae6 100644 (file)
@@ -5,7 +5,7 @@ define( 'REPORTING_INTERVAL', 100 );
 if ( !defined( 'MEDIAWIKI' ) ) {
        $optionsWithArgs = array( 'm' );
 
-       require_once( '../commandLine.inc' );
+       require_once( dirname(__FILE__) . '/../commandLine.inc' );
        require_once( 'includes/ExternalStoreDB.php' );
 
        resolveStubs();