Skip to content

Commit 56e889e

Browse files
Make sure to use the right php binary
In order to use the same binary that was used to execute Composer the PHP_BINARY constant is used.
1 parent def8812 commit 56e889e

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/ComposerPlugin.php

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -218,7 +218,9 @@ private function runCaptainCommand(string $command): void
218218
}
219219

220220
// sub process settings
221-
$cmd = $executable . ' ' . $command . $ansi . $interaction . $forceOrSkip . $configuration . $repository;
221+
$cmd = PHP_BINARY . ' ' . $executable . ' ' . $command
222+
. $ansi . $interaction . $forceOrSkip
223+
. $configuration . $repository;
222224
$pipes = [];
223225
$spec = [
224226
0 => ['file', 'php://stdin', 'r'],

0 commit comments

Comments
 (0)