X-Git-Url: http://git.cyclocoop.org/?a=blobdiff_plain;f=maintenance%2Finstall.php;h=438e9dc4789f45c876c12231f1e9b828cd90edc9;hb=501d31060ed903bd22846258221816bb93542dd9;hp=cac3009a8f49faf37f997f4e25e9424b6af394b1;hpb=29115b9e5312bff77223ae2210ab372b0ada3f4d;p=lhc%2Fweb%2Fwiklou.git diff --git a/maintenance/install.php b/maintenance/install.php index cac3009a8f..438e9dc478 100644 --- a/maintenance/install.php +++ b/maintenance/install.php @@ -88,6 +88,8 @@ class CommandLineInstaller extends Maintenance { false, true ); */ $this->addOption( 'env-checks', "Run environment checks only, don't change anything" ); + + $this->addOption( 'with-extensions', "Detect and include extensions" ); } public function getDbType() { @@ -132,11 +134,11 @@ class CommandLineInstaller extends Maintenance { $this->error( 'WARNING: You have provided the options "dbpass" and "dbpassfile". ' . 'The content of "dbpassfile" overrides "dbpass".' ); } - MediaWiki\suppressWarnings(); + Wikimedia\suppressWarnings(); $dbpass = file_get_contents( $dbpassfile ); // returns false on failure - MediaWiki\restoreWarnings(); + Wikimedia\restoreWarnings(); if ( $dbpass === false ) { - $this->error( "Couldn't open $dbpassfile", true ); + $this->fatalError( "Couldn't open $dbpassfile" ); } $this->mOptions['dbpass'] = trim( $dbpass, "\r\n" ); } @@ -149,15 +151,15 @@ class CommandLineInstaller extends Maintenance { $this->error( 'WARNING: You have provided the options "pass" and "passfile". ' . 'The content of "passfile" overrides "pass".' ); } - MediaWiki\suppressWarnings(); + Wikimedia\suppressWarnings(); $pass = file_get_contents( $passfile ); // returns false on failure - MediaWiki\restoreWarnings(); + Wikimedia\restoreWarnings(); if ( $pass === false ) { - $this->error( "Couldn't open $passfile", true ); + $this->fatalError( "Couldn't open $passfile" ); } $this->mOptions['pass'] = trim( $pass, "\r\n" ); } elseif ( $this->getOption( 'pass' ) === null ) { - $this->error( 'You need to provide the option "pass" or "passfile"', true ); + $this->fatalError( 'You need to provide the option "pass" or "passfile"' ); } } @@ -168,6 +170,6 @@ class CommandLineInstaller extends Maintenance { } } -$maintClass = 'CommandLineInstaller'; +$maintClass = CommandLineInstaller::class; require_once RUN_MAINTENANCE_IF_MAIN;