Created
July 21, 2020 19:25
-
-
Save bosunski/d099674bfa06d894bd766c52e399da94 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
use React\ChildProcess\Process; | |
use React\EventLoop\Factory; | |
use function React\Promise\Stream\buffer; | |
require "vendor/autoload.php"; | |
$proc = new Process("composer"); | |
$proc->start($loop = Factory::create()); | |
buffer($proc->stdout)->then(function ($bufferedOutput) { | |
echo $bufferedOutput; | |
}); | |
$loop->run(); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment