Merge remote-tracking branch 'johnstevenson/unlink-fix-2'
commit
16a9839688
|
@ -17,6 +17,7 @@ use Composer\Json\JsonFile;
|
|||
use Composer\IO\IOInterface;
|
||||
use Composer\Repository\ComposerRepository;
|
||||
use Composer\Repository\RepositoryManager;
|
||||
use Composer\Util\Filesystem;
|
||||
use Composer\Util\ProcessExecutor;
|
||||
use Composer\Util\RemoteFilesystem;
|
||||
use Symfony\Component\Console\Formatter\OutputFormatterStyle;
|
||||
|
@ -86,6 +87,7 @@ class Factory
|
|||
'cache-vcs-dir' => array('/cache.git' => '/*', '/cache.hg' => '/*'),
|
||||
'cache-files-dir' => array('/cache.files' => '/*'),
|
||||
);
|
||||
$filesystem = new Filesystem();
|
||||
foreach ($legacyPaths as $key => $oldPaths) {
|
||||
foreach ($oldPaths as $oldPath => $match) {
|
||||
$dir = $config->get($key);
|
||||
|
@ -105,7 +107,7 @@ class Factory
|
|||
@rename($child, $dir.'/'.basename($child));
|
||||
}
|
||||
}
|
||||
@unlink($oldPath);
|
||||
$filesystem->removeDirectory($oldPath);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue