1
0
Fork 0

Add deprecated notice to show command

pull/5068/head
Barry vd. Heuvel 2016-03-15 20:46:00 +01:00
parent ac606e4dc1
commit 80be9a2c98
1 changed files with 16 additions and 0 deletions

View File

@ -294,6 +294,22 @@ EOT
$path = strtok(realpath($composer->getInstallationManager()->getInstallPath($package)), "\r\n");
$io->write(' ' . $path, false);
}
if ($showLatest && $package->isAbandoned()) {
$replacement = (is_string($package->getReplacementPackage()))
? 'Use ' . $package->getReplacementPackage() . ' instead'
: 'No replacement was suggested';
$io->write('');
$io->write(
sprintf(
"<warning>Package %s is abandoned, you should avoid using it. %s.</warning>",
$package->getPrettyName(),
$replacement
),
false
);
}
} else {
$io->write($indent . $package, false);
}