X-Git-Url: http://git.cyclocoop.org/?a=blobdiff_plain;f=maintenance%2FcommandLine.inc;h=fd13bdcb146b05cb8828ecd7f0c2805db7273f96;hb=ad787f1574b7598868e12d1a4a9bba3ca23d4a8f;hp=f868b0bfc78369fb5bb718de72133b090e24326d;hpb=9118b17901988a3f5a55932e8f582a11aa7f8efa;p=lhc%2Fweb%2Fwiklou.git diff --git a/maintenance/commandLine.inc b/maintenance/commandLine.inc index f868b0bfc7..fd13bdcb14 100644 --- a/maintenance/commandLine.inc +++ b/maintenance/commandLine.inc @@ -1,41 +1,47 @@ addOption( $name, '', false, true ); + } + } + + public function getDbType() { + global $wgUseNormalUser; + + return ( isset( $wgUseNormalUser ) && $wgUseNormalUser ) ? + Maintenance::DB_STD : Maintenance::DB_ADMIN; + } + + /** + * No help, it would just be misleading since it misses custom options + */ + protected function maybeHelp( $force = false ) { + if ( !$force ) + return; + parent::maybeHelp( true ); + } + + public function execute() { + global $args, $options; + $args = $this->mArgs; + $options = $this->mOptions; + } } +$maintClass = 'CommandLineInc'; +require( DO_MAINTENANCE ); -$wgCommandLineMode = true; -$DP = "../includes"; -include_once( $settingsFile ); -ini_set( "include_path", "../includes$sep../languages$sep$newpath$IP$sep$include_path" ); - -$wgUsePHPTal = false; -define("MEDIAWIKI",true); -include_once( "Setup.php" ); -include_once( "./InitialiseMessages.inc" ); -include_once( "../install-utils.inc" ); -$wgTitle = Title::newFromText( "Rebuild messages script" ); -$wgCommandLineMode = true; -set_time_limit(0); -?>