mirror of
https://code.castopod.org/adaures/castopod
synced 2025-04-19 13:01:19 +00:00

- update .devcontainer settings: remove auto-formatting for php + set intelephense as default formatter - remove prettier php plugin as it lacks php 8 support - add captain hook action for checking style pre-commit - fix style with ecs on all files except views
30 lines
982 B
PHP
30 lines
982 B
PHP
<?php
|
|
|
|
use Symfony\Component\DependencyInjection\Loader\Configurator\ContainerConfigurator;
|
|
use Symplify\EasyCodingStandard\ValueObject\Option;
|
|
use Symplify\EasyCodingStandard\ValueObject\Set\SetList;
|
|
|
|
return static function (ContainerConfigurator $containerConfigurator): void {
|
|
$parameters = $containerConfigurator->parameters();
|
|
|
|
// alternative to CLI arguments, easier to maintain and extend
|
|
$parameters->set(Option::PATHS, [
|
|
__DIR__ . '/app',
|
|
__DIR__ . '/tests',
|
|
__DIR__ . '/public',
|
|
]);
|
|
|
|
$parameters->set(Option::SKIP, [
|
|
// TODO: restrict some rules for views?
|
|
__DIR__ . '/app/Views/*',
|
|
|
|
// skip specific generated files
|
|
__DIR__ . '/app/Language/*/PersonsTaxonomy.php',
|
|
]);
|
|
|
|
$containerConfigurator->import(SetList::PSR_12);
|
|
$containerConfigurator->import(SetList::SYMPLIFY);
|
|
$containerConfigurator->import(SetList::COMMON);
|
|
$containerConfigurator->import(SetList::CLEAN_CODE);
|
|
};
|