minor #25257 [link] clear the cache after linking (dunglas)

This PR was squashed before being merged into the 2.7 branch (closes #25257).

Discussion
----------

[link] clear the cache after linking

| Q             | A
| ------------- | ---
| Branch?       | 2.7
| Bug fix?      | yes
| New feature?  | no <!-- don't forget to update src/**/CHANGELOG.md files -->
| BC breaks?    | no
| Deprecations? | no <!-- don't forget to update UPGRADE-*.md files -->
| Tests pass?   | yes
| Fixed tickets | n/a
| License       | MIT
| Doc PR        | n/a

Clearing the cache after linking prevents fatal errors when a container already exists.

Commits
-------

05c3c81a20 [link] clear the cache after linking
This commit is contained in:
Fabien Potencier 2017-12-01 17:33:23 -08:00
commit de3a25a474
1 changed files with 4 additions and 0 deletions

4
link
View File

@ -60,3 +60,7 @@ foreach (glob("$argv[1]/vendor/symfony/*", GLOB_ONLYDIR | GLOB_NOSORT) as $dir)
$filesystem->symlink($sfDir, $dir);
echo "\"$package\" has been linked to \"$sfPackages[$package]\".".PHP_EOL;
}
foreach (glob("$argv[1]/var/cache/*") as $cacheDir) {
$filesystem->remove($cacheDir);
}