for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
/*
* This file is part of `Composer as a service`.
*
* (c) Pascal Borreli <[email protected]>
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace Ayaline\Bundle\ComposerBundle\Consumer\Step;
use Sonata\NotificationBundle\Consumer\ConsumerEvent;
/**
* @author Hubert Moutot <[email protected]>
class ComposerInstalledStep extends AbstractStep
{
* {@inheritdoc}
public function execute(ConsumerEvent $event, $directory)
$output = null;
$workingDirectory = $this->workingTempPath.'/'.$directory;
$process = $this->runProcess(sprintf('%s show --installed', $this->composerBinPath), $workingDirectory, $output);
if ($process->isSuccessful()) {
$this->triggerComposerInstalled($event, ['message' => $process->getOutput()]);
}
return 0;