Assume -i when running composer show --tree without arg
parent
48420a2411
commit
1a8aedaa9d
|
@ -75,11 +75,17 @@ EOT
|
||||||
$this->initStyles($output);
|
$this->initStyles($output);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
$composer = $this->getComposer(false);
|
||||||
|
$io = $this->getIO();
|
||||||
|
|
||||||
|
if ($input->getOption('tree') && !$input->getOption('installed')) {
|
||||||
|
$io->writeError('The --tree (-t) option is only usable in combination with --installed (-i) or by passing a single package name to show, assuming -i');
|
||||||
|
$input->setOption('installed', true);
|
||||||
|
}
|
||||||
|
|
||||||
// init repos
|
// init repos
|
||||||
$platformRepo = new PlatformRepository;
|
$platformRepo = new PlatformRepository;
|
||||||
|
|
||||||
$composer = $this->getComposer(false);
|
|
||||||
$io = $this->getIO();
|
|
||||||
if ($input->getOption('self')) {
|
if ($input->getOption('self')) {
|
||||||
$package = $this->getComposer()->getPackage();
|
$package = $this->getComposer()->getPackage();
|
||||||
$repos = $installedRepo = new ArrayRepository(array($package));
|
$repos = $installedRepo = new ArrayRepository(array($package));
|
||||||
|
@ -147,11 +153,6 @@ EOT
|
||||||
|
|
||||||
// show tree view if requested
|
// show tree view if requested
|
||||||
if ($input->getOption('tree')) {
|
if ($input->getOption('tree')) {
|
||||||
if (!$input->getOption('installed')) {
|
|
||||||
$io->writeError('The --tree (-t) option is only usable in combination with --installed (-i) or by passing a single package name to show');
|
|
||||||
return 1;
|
|
||||||
}
|
|
||||||
|
|
||||||
$rootPackage = $this->getComposer()->getPackage();
|
$rootPackage = $this->getComposer()->getPackage();
|
||||||
$rootRequires = array_map(
|
$rootRequires = array_map(
|
||||||
'strtolower',
|
'strtolower',
|
||||||
|
|
Loading…
Reference in New Issue