Make LocalisationCache a service
[lhc/web/wiklou.git] / maintenance / hhvm / makeRepo.php
index f77f5b9..9502cdc 100644 (file)
@@ -1,5 +1,7 @@
 <?php
 
+use MediaWiki\Shell\Shell;
+
 require __DIR__ . '/../Maintenance.php';
 
 class HHVMMakeRepo extends Maintenance {
@@ -103,7 +105,7 @@ class HHVMMakeRepo extends Maintenance {
 
                $hhvm = $this->getOption( 'hhvm', 'hhvm' );
                $verbose = $this->getOption( 'verbose', 3 );
-               $cmd = wfEscapeShellArg(
+               $cmd = Shell::escape(
                        $hhvm,
                        '--hphp',
                        '--target', 'hhbc',
@@ -149,6 +151,7 @@ class HHVMMakeRepo extends Maintenance {
                        ),
                        RecursiveIteratorIterator::LEAVES_ONLY
                );
+               /** @var SplFileInfo $fileInfo */
                foreach ( $iter as $file => $fileInfo ) {
                        if ( $fileInfo->isFile() ) {
                                $files[] = $file;
@@ -157,5 +160,5 @@ class HHVMMakeRepo extends Maintenance {
        }
 }
 
-$maintClass = 'HHVMMakeRepo';
+$maintClass = HHVMMakeRepo::class;
 require RUN_MAINTENANCE_IF_MAIN;