8000 bug #9237 [FrameworkBundle] assets:install command should mirror .dot… · symfony/symfony@0375dc8 · GitHub
[go: up one dir, main page]

Skip to content

Commit 0375dc8

Browse files
committed
bug #9237 [FrameworkBundle] assets:install command should mirror .dotfiles (.htaccess) (FineWolf)
This PR was submitted for the master branch but it was merged into the 2.2 branch instead (closes #9237). Discussion ---------- [FrameworkBundle] assets:install command should mirror .dotfiles (.htaccess) | Q | A | ------------- | --- | Bug fix? | yes | New feature? | no | BC breaks? | no | Deprecations? | no | Tests pass? | yes | Fixed tickets | - | License | MIT | Doc PR | - The `assets:install` command currently ignores all *.dotfiles* when mirroring the `Resources\public` folders of bundles. This can lead to issues when *.htaccess* files are required for some public assets (ie.: CORS headers for font files to be served via Cloudfront). Since the assets being installed are clearly in a folder called `public`, we can safely assume that those files are in fact supposed to be accessible and copy them over with the normal files. Commits ------- 9c884a0 [FrameworkBundle] assets:install command should mirror .dotfiles (.htaccess)
2 parents 2ae07b5 + 6f48f8e commit 0375dc8

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/Symfony/Bundle/FrameworkBundle/Command/AssetsInstallCommand.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,7 @@ protected function execute(InputInterface $input, OutputInterface $output)
103103
} else {
104104
$filesystem->mkdir($targetDir, 0777);
105105
// We use a custom iterator to ignore VCS files
106-
$filesystem->mirror($originDir, $targetDir, Finder::create()->in($originDir));
106+
$filesystem->mirror($originDir, $targetDir, Finder::create()->ignoreDotFiles(false)->in($originDir));
107107
}
108108
}
109109
}

0 commit comments

Comments
 (0)
0