|
@@ -52,6 +52,9 @@ class AssetsInstallCommand extends Command
|
|
|
|
|
|
$filesystem = new Filesystem();
|
|
|
|
|
|
+ // Create the bundles directory otherwise symlink will fail.
|
|
|
+ $filesystem->mkdirs($input->getArgument('target').'/bundles/', 0777);
|
|
|
+
|
|
|
foreach ($this->container->get('kernel')->getBundles() as $bundle) {
|
|
|
if (is_dir($originDir = $bundle->getPath().'/Resources/public')) {
|
|
|
$output->writeln(sprintf('Installing assets for <comment>%s\\%s</comment>', $bundle->getNamespacePrefix(), $bundle->getName()));
|
|
@@ -63,7 +66,7 @@ class AssetsInstallCommand extends Command
|
|
|
if ($input->getOption('symlink')) {
|
|
|
$filesystem->symlink($originDir, $targetDir);
|
|
|
} else {
|
|
|
- mkdir($targetDir, 0777, true);
|
|
|
+ $filesystem->mkdirs($targetDir, 0777);
|
|
|
$filesystem->mirror($originDir, $targetDir);
|
|
|
}
|
|
|
}
|