1
0
Fork 0
mirror of https://github.com/wallabag/wallabag.git synced 2025-08-01 17:38:38 +00:00

Merge pull request #6809 from yguedidi/replace-kernel.root_dir-by-kernel.project_dir

Replace kernel.root_dir by kernel.project_dir
This commit is contained in:
Kevin Decherf 2023-08-13 20:02:06 +02:00 committed by GitHub
commit 48226ad6e5
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
5 changed files with 12 additions and 17 deletions

View file

@ -62,11 +62,6 @@ class AppKernel extends Kernel
return $bundles;
}
public function getRootDir()
{
return __DIR__;
}
public function getCacheDir()
{
return dirname(__DIR__) . '/var/cache/' . $this->getEnvironment();
@ -79,7 +74,7 @@ class AppKernel extends Kernel
public function registerContainerConfiguration(LoaderInterface $loader)
{
$loader->load($this->getRootDir() . '/config/config_' . $this->getEnvironment() . '.yml');
$loader->load($this->getProjectDir() . '/app/config/config_' . $this->getEnvironment() . '.yml');
$loader->load(function ($container) {
if ($container->getParameter('use_webpack_dev_server')) {

View file

@ -12,7 +12,7 @@ services:
autoconfigure: true
public: true
bind:
$rootDir: '%kernel.root_dir%'
$projectDir: '%kernel.project_dir%'
$debug: '%kernel.debug%'
$defaultLocale: '%kernel.default_locale%'
$wallabagUrl: '%domain_name%'

View file

@ -2,16 +2,16 @@ const path = require('path');
const webpack = require('webpack');
const StyleLintPlugin = require('stylelint-webpack-plugin');
const rootDir = path.resolve(__dirname, '../../../');
const projectDir = path.resolve(__dirname, '../../../');
module.exports = {
entry: {
material: path.join(rootDir, './app/Resources/static/themes/material/index.js'),
public: path.join(rootDir, './app/Resources/static/themes/_global/share.js'),
material: path.join(projectDir, './app/Resources/static/themes/material/index.js'),
public: path.join(projectDir, './app/Resources/static/themes/_global/share.js'),
},
output: {
filename: '[name].js',
path: path.resolve(rootDir, 'web/wallassets'),
path: path.resolve(projectDir, 'web/wallassets'),
publicPath: '',
},
plugins: [
@ -31,7 +31,7 @@ module.exports = {
],
resolve: {
alias: {
jquery: path.join(rootDir, 'node_modules/jquery/dist/jquery.js'),
jquery: path.join(projectDir, 'node_modules/jquery/dist/jquery.js'),
},
},
};