From d81f562b712f2387fa02290bf2ca86392ab356f2 Mon Sep 17 00:00:00 2001 From: Pierre Schmitz Date: Wed, 11 Oct 2006 20:21:25 +0000 Subject: Aktualisierung auf Version 1.8.1 --- maintenance/commandLine.inc | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) (limited to 'maintenance/commandLine.inc') diff --git a/maintenance/commandLine.inc b/maintenance/commandLine.inc index 2bb5389e..2549057e 100644 --- a/maintenance/commandLine.inc +++ b/maintenance/commandLine.inc @@ -28,16 +28,15 @@ if ( !isset( $optionsWithArgs ) ) { $optionsWithArgs[] = 'conf'; # For specifying the location of LocalSettings.php $self = array_shift( $argv ); -$self = __FILE__; -$IP = realpath( dirname( $self ) . '/..' ); +$IP = realpath( dirname( __FILE__ ) . '/..' ); #chdir( $IP ); +require_once( "$IP/StartProfiler.php" ); $options = array(); $args = array(); # Parse arguments - for( $arg = reset( $argv ); $arg !== false; $arg = next( $argv ) ) { if ( $arg == '--' ) { # End of options, remainder should be considered arguments @@ -133,6 +132,7 @@ if ( file_exists( '/home/wikipedia/common/langlist' ) ) { # This is for the IRC scripts, which now run as the apache user # The apache user doesn't have access to the wikiadmin_pass command if ( $_ENV['USER'] == 'apache' ) { + #if ( posix_geteuid() == 48 ) { $wgUseNormalUser = true; } @@ -141,7 +141,7 @@ if ( file_exists( '/home/wikipedia/common/langlist' ) ) { $DP = $IP; ini_set( 'include_path', ".:$IP:$IP/includes:$IP/languages:$IP/maintenance" ); - require_once( $IP.'/includes/ProfilerStub.php' ); + #require_once( $IP.'/includes/ProfilerStub.php' ); require_once( $IP.'/includes/Defines.php' ); require_once( $IP.'/CommonSettings.php' ); @@ -168,7 +168,7 @@ if ( file_exists( '/home/wikipedia/common/langlist' ) ) { } $wgCommandLineMode = true; $DP = $IP; - require_once( $IP.'/includes/ProfilerStub.php' ); + #require_once( $IP.'/includes/ProfilerStub.php' ); require_once( $IP.'/includes/Defines.php' ); require_once( $settingsFile ); ini_set( 'include_path', ".$sep$IP$sep$IP/includes$sep$IP/languages$sep$IP/maintenance" ); @@ -202,9 +202,11 @@ if ( defined( 'MW_CMDLINE_CALLBACK' ) ) { ini_set( 'memory_limit', -1 ); +$wgShowSQLErrors = true; + require_once( 'Setup.php' ); require_once( 'install-utils.inc' ); -$wgTitle = Title::newFromText( 'Command line script' ); +$wgTitle = null; # Much much faster startup than creating a title object set_time_limit(0); // -------------------------------------------------------------------- -- cgit v1.2.2