1
0
Fork 0

Add BC warning for older lock files

pull/668/merge
Jordi Boggiano 2012-05-09 17:31:27 +02:00
parent fafd09a7ba
commit 45a2070fee
1 changed files with 6 additions and 0 deletions

View File

@ -89,6 +89,12 @@ class Locker
$repo = $dev ? $this->repositoryManager->getLocalDevRepository() : $this->repositoryManager->getLocalRepository();
foreach ($lockedPackages as $info) {
// TODO BC remove this after June 10th
if (isset($info['alias']) && empty($warned)) {
$warned = true;
echo 'BC warning: your lock file appears to be of an older format than this composer version, it is recommended to run composer update'.PHP_EOL;
}
$resolvedVersion = !empty($info['alias-version']) ? $info['alias-version'] : $info['version'];
// try to find the package in the local repo (best match)