Skip to content

Commit

Permalink
[FEATURE] Use --classmap-authoritative for composer install
Browse files Browse the repository at this point in the history
This creates an optimized class map and denies lookups
for classes not in the class map, which speeds up class_exist
checks by a lot.

Downside is only a slightly higher build time.
  • Loading branch information
helhum committed May 1, 2016
1 parent dfbdca8 commit d73d421
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion Tests/Unit/Task/Composer/InstallTaskTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ public function executeUserConfiguredComposerCommand()
);

$this->task->execute($this->node, $this->application, $this->deployment, $options);
$this->assertCommandExecuted('/^\/my\/path\/to\/composer.phar install --no-ansi --no-interaction --no-dev --no-progress 2>&1$/');
$this->assertCommandExecuted('/^\/my\/path\/to\/composer.phar install --no-ansi --no-interaction --no-dev --no-progress --classmap-authoritative 2>&1$/');
}

/**
Expand Down
2 changes: 1 addition & 1 deletion src/Task/Composer/InstallTask.php
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ protected function buildComposerInstallCommands($manifestPath, array $options)
}
return array(
'cd ' . escapeshellarg($manifestPath),
escapeshellcmd($options['composerCommandPath']) . ' install --no-ansi --no-interaction --no-dev --no-progress 2>&1',
escapeshellcmd($options['composerCommandPath']) . ' install --no-ansi --no-interaction --no-dev --no-progress --classmap-authoritative 2>&1',
);
}

Expand Down

0 comments on commit d73d421

Please sign in to comment.