$lock = new ComposerLock( $lockLocation );
$json = new ComposerJson( $jsonLocation );
- if ( $lock->getHash() === $json->getHash() ) {
- $this->output( "Your composer.lock file is up to date with current dependencies!\n" );
- return;
- }
- // Out of date, lets figure out which dependencies are old
+ // Check all the dependencies to see if any are old
$found = false;
$installed = $lock->getInstalledDependencies();
foreach ( $json->getRequiredDependencies() as $name => $version ) {
1
);
} else {
- // The hash is the entire composer.json file,
- // so it can be updated without any of the dependencies changing
// We couldn't find any out-of-date dependencies, so assume everything is ok!
$this->output( "Your composer.lock file is up to date with current dependencies!\n" );
}