mirror of
https://github.com/deployphp/deployer.git
synced 2025-02-24 17:22:41 +01:00
Merge pull request #904 from maurice2k/feature/throw-process-failed-exception
Adjusted runLocally to throw ProcessFailedException in case of error
This commit is contained in:
commit
899190a644
@ -20,6 +20,7 @@ use Monolog\Logger;
|
||||
use Symfony\Component\Console\Question\ConfirmationQuestion;
|
||||
use Symfony\Component\Console\Question\Question;
|
||||
use Symfony\Component\Finder\Finder;
|
||||
use Symfony\Component\Process\Exception\ProcessFailedException;
|
||||
use Symfony\Component\Process\Process;
|
||||
use Deployer\Cluster\ClusterFactory;
|
||||
use Symfony\Component\Console\Input\InputArgument;
|
||||
@ -353,7 +354,7 @@ function runLocally($command, $timeout = 60)
|
||||
});
|
||||
|
||||
if (!$process->isSuccessful()) {
|
||||
throw new \RuntimeException($process->getErrorOutput());
|
||||
throw new ProcessFailedException($process);
|
||||
}
|
||||
|
||||
$output = $process->getOutput();
|
||||
|
Loading…
x
Reference in New Issue
Block a user