Skip to content

Commit e7bb6a3

Browse files
Merge pull request #2818 from dpfaffenbauer/issue/installer
[FrontendBundle] install css/js (public) files too
2 parents b61c372 + 5b58342 commit e7bb6a3

File tree

2 files changed

+34
-0
lines changed

2 files changed

+34
-0
lines changed
Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
<?php
2+
3+
declare(strict_types=1);
4+
5+
/*
6+
* CoreShop
7+
*
8+
* This source file is available under two different licenses:
9+
* - GNU General Public License version 3 (GPLv3)
10+
* - CoreShop Commercial License (CCL)
11+
* Full copyright and license information is available in
12+
* LICENSE.md which is distributed with this source code.
13+
*
14+
* @copyright Copyright (c) CoreShop GmbH (https://www.coreshop.org)
15+
* @license https://www.coreshop.org/license GPLv3 and CCL
16+
*
17+
*/
18+
19+
namespace CoreShop\Bundle\FrontendBundle\Installer;
20+
21+
use Symfony\Component\Filesystem\Filesystem;
22+
23+
class PublicInstaller implements FrontendInstallerInterface
24+
{
25+
public function installFrontend(string $frontendBundlePath, string $rootPath, string $templatePath): void
26+
{
27+
$fs = new Filesystem();
28+
$fs->mirror($frontendBundlePath.'/Resources/public/static', $rootPath.'/public/coreshop/static');
29+
}
30+
}

src/CoreShop/Bundle/FrontendBundle/Resources/config/services/frontend-installer.yaml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,10 @@ services:
1515
tags:
1616
- { name: coreshop.frontend.installer }
1717

18+
CoreShop\Bundle\FrontendBundle\Installer\PublicInstaller:
19+
tags:
20+
- { name: coreshop.frontend.installer }
21+
1822
CoreShop\Bundle\FrontendBundle\Installer\FrontendInstallerInterface: '@CoreShop\Bundle\FrontendBundle\Installer\FrontendInstaller'
1923
CoreShop\Bundle\FrontendBundle\Installer\FrontendInstaller:
2024
arguments:

0 commit comments

Comments
 (0)