1
0
Fork 0

Validate composer show with --tree and --path options set (#8390)

pull/8401/head
Armando Miani 2019-10-29 15:06:07 +01:00 committed by Jordi Boggiano
parent 8bcacc8a3a
commit 82d939d7f7
1 changed files with 6 additions and 0 deletions

View File

@ -129,6 +129,12 @@ EOT
return 1;
}
if ($input->getOption('tree') && $input->getOption('path')) {
$io->writeError('The --tree (-t) option is not usable in combination with --path (-P)');
return 1;
}
$format = $input->getOption('format');
if (!in_array($format, array('text', 'json'))) {
$io->writeError(sprintf('Unsupported format "%s". See help for supported formats.', $format));