Passed
Push — master ( f32054...0e8b83 )
by Tarmo
107:11 queued 42:11
created
Labels
Severity
1
<?php
2
declare(strict_types = 1);
3
/**
4
 * /ecs.php
5
 *
6
 * Configuration for `EasyCodingStandard` tool.
7
 *
8
 * @author TLe, Tarmo Leppänen <[email protected]>
9
 */
10
11
use PhpCsFixer\Fixer\ArrayNotation\NoMultilineWhitespaceAroundDoubleArrowFixer;
0 ignored issues
show
The type PhpCsFixer\Fixer\ArrayNo...eAroundDoubleArrowFixer was not found. Maybe you did not declare it correctly or list all dependencies?

The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g. excluded_paths: ["lib/*"], you can move it to the dependency path list as follows:

filter:
    dependency_paths: ["lib/*"]

For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths

Loading history...
12
use PhpCsFixer\Fixer\CastNotation\CastSpacesFixer;
0 ignored issues
show
The type PhpCsFixer\Fixer\CastNotation\CastSpacesFixer was not found. Maybe you did not declare it correctly or list all dependencies?

The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g. excluded_paths: ["lib/*"], you can move it to the dependency path list as follows:

filter:
    dependency_paths: ["lib/*"]

For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths

Loading history...
13
use PhpCsFixer\Fixer\ClassNotation\ClassAttributesSeparationFixer;
0 ignored issues
show
The type PhpCsFixer\Fixer\ClassNo...tributesSeparationFixer was not found. Maybe you did not declare it correctly or list all dependencies?

The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g. excluded_paths: ["lib/*"], you can move it to the dependency path list as follows:

filter:
    dependency_paths: ["lib/*"]

For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths

Loading history...
14
use PhpCsFixer\Fixer\ControlStructure\YodaStyleFixer;
0 ignored issues
show
The type PhpCsFixer\Fixer\ControlStructure\YodaStyleFixer was not found. Maybe you did not declare it correctly or list all dependencies?

The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g. excluded_paths: ["lib/*"], you can move it to the dependency path list as follows:

filter:
    dependency_paths: ["lib/*"]

For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths

Loading history...
15
use PhpCsFixer\Fixer\FunctionNotation\SingleLineThrowFixer;
0 ignored issues
show
The type PhpCsFixer\Fixer\Functio...on\SingleLineThrowFixer was not found. Maybe you did not declare it correctly or list all dependencies?

The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g. excluded_paths: ["lib/*"], you can move it to the dependency path list as follows:

filter:
    dependency_paths: ["lib/*"]

For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths

Loading history...
16
use PhpCsFixer\Fixer\Import\OrderedImportsFixer;
0 ignored issues
show
The type PhpCsFixer\Fixer\Import\OrderedImportsFixer was not found. Maybe you did not declare it correctly or list all dependencies?

The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g. excluded_paths: ["lib/*"], you can move it to the dependency path list as follows:

filter:
    dependency_paths: ["lib/*"]

For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths

Loading history...
17
use PhpCsFixer\Fixer\LanguageConstruct\DeclareEqualNormalizeFixer;
0 ignored issues
show
The type PhpCsFixer\Fixer\Languag...lareEqualNormalizeFixer was not found. Maybe you did not declare it correctly or list all dependencies?

The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g. excluded_paths: ["lib/*"], you can move it to the dependency path list as follows:

filter:
    dependency_paths: ["lib/*"]

For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths

Loading history...
18
use PhpCsFixer\Fixer\NamespaceNotation\NoBlankLinesBeforeNamespaceFixer;
0 ignored issues
show
The type PhpCsFixer\Fixer\Namespa...nesBeforeNamespaceFixer was not found. Maybe you did not declare it correctly or list all dependencies?

The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g. excluded_paths: ["lib/*"], you can move it to the dependency path list as follows:

filter:
    dependency_paths: ["lib/*"]

For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths

Loading history...
19
use PhpCsFixer\Fixer\Operator\ConcatSpaceFixer;
0 ignored issues
show
The type PhpCsFixer\Fixer\Operator\ConcatSpaceFixer was not found. Maybe you did not declare it correctly or list all dependencies?

The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g. excluded_paths: ["lib/*"], you can move it to the dependency path list as follows:

filter:
    dependency_paths: ["lib/*"]

For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths

Loading history...
20
use PhpCsFixer\Fixer\Operator\IncrementStyleFixer;
0 ignored issues
show
The type PhpCsFixer\Fixer\Operator\IncrementStyleFixer was not found. Maybe you did not declare it correctly or list all dependencies?

The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g. excluded_paths: ["lib/*"], you can move it to the dependency path list as follows:

filter:
    dependency_paths: ["lib/*"]

For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths

Loading history...
21
use PhpCsFixer\Fixer\Operator\NotOperatorWithSuccessorSpaceFixer;
0 ignored issues
show
The type PhpCsFixer\Fixer\Operato...WithSuccessorSpaceFixer was not found. Maybe you did not declare it correctly or list all dependencies?

The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g. excluded_paths: ["lib/*"], you can move it to the dependency path list as follows:

filter:
    dependency_paths: ["lib/*"]

For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths

Loading history...
22
use PhpCsFixer\Fixer\Phpdoc\NoSuperfluousPhpdocTagsFixer;
0 ignored issues
show
The type PhpCsFixer\Fixer\Phpdoc\...erfluousPhpdocTagsFixer was not found. Maybe you did not declare it correctly or list all dependencies?

The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g. excluded_paths: ["lib/*"], you can move it to the dependency path list as follows:

filter:
    dependency_paths: ["lib/*"]

For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths

Loading history...
23
use PhpCsFixer\Fixer\Phpdoc\PhpdocAlignFixer;
0 ignored issues
show
The type PhpCsFixer\Fixer\Phpdoc\PhpdocAlignFixer was not found. Maybe you did not declare it correctly or list all dependencies?

The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g. excluded_paths: ["lib/*"], you can move it to the dependency path list as follows:

filter:
    dependency_paths: ["lib/*"]

For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths

Loading history...
24
use PhpCsFixer\Fixer\Phpdoc\PhpdocNoPackageFixer;
0 ignored issues
show
The type PhpCsFixer\Fixer\Phpdoc\PhpdocNoPackageFixer was not found. Maybe you did not declare it correctly or list all dependencies?

The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g. excluded_paths: ["lib/*"], you can move it to the dependency path list as follows:

filter:
    dependency_paths: ["lib/*"]

For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths

Loading history...
25
use PhpCsFixer\Fixer\Phpdoc\PhpdocSeparationFixer;
0 ignored issues
show
The type PhpCsFixer\Fixer\Phpdoc\PhpdocSeparationFixer was not found. Maybe you did not declare it correctly or list all dependencies?

The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g. excluded_paths: ["lib/*"], you can move it to the dependency path list as follows:

filter:
    dependency_paths: ["lib/*"]

For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths

Loading history...
26
use PhpCsFixer\Fixer\Phpdoc\PhpdocSummaryFixer;
0 ignored issues
show
The type PhpCsFixer\Fixer\Phpdoc\PhpdocSummaryFixer was not found. Maybe you did not declare it correctly or list all dependencies?

The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g. excluded_paths: ["lib/*"], you can move it to the dependency path list as follows:

filter:
    dependency_paths: ["lib/*"]

For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths

Loading history...
27
use PhpCsFixer\Fixer\PhpTag\BlankLineAfterOpeningTagFixer;
0 ignored issues
show
The type PhpCsFixer\Fixer\PhpTag\...ineAfterOpeningTagFixer was not found. Maybe you did not declare it correctly or list all dependencies?

The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g. excluded_paths: ["lib/*"], you can move it to the dependency path list as follows:

filter:
    dependency_paths: ["lib/*"]

For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths

Loading history...
28
use PhpCsFixer\Fixer\Whitespace\BlankLineBeforeStatementFixer;
0 ignored issues
show
The type PhpCsFixer\Fixer\Whitesp...ineBeforeStatementFixer was not found. Maybe you did not declare it correctly or list all dependencies?

The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g. excluded_paths: ["lib/*"], you can move it to the dependency path list as follows:

filter:
    dependency_paths: ["lib/*"]

For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths

Loading history...
29
use SlevomatCodingStandard\Sniffs\Functions\UnusedParameterSniff;
0 ignored issues
show
The type SlevomatCodingStandard\S...ns\UnusedParameterSniff was not found. Maybe you did not declare it correctly or list all dependencies?

The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g. excluded_paths: ["lib/*"], you can move it to the dependency path list as follows:

filter:
    dependency_paths: ["lib/*"]

For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths

Loading history...
30
use SlevomatCodingStandard\Sniffs\Whitespaces\DuplicateSpacesSniff;
0 ignored issues
show
The type SlevomatCodingStandard\S...es\DuplicateSpacesSniff was not found. Maybe you did not declare it correctly or list all dependencies?

The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g. excluded_paths: ["lib/*"], you can move it to the dependency path list as follows:

filter:
    dependency_paths: ["lib/*"]

For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths

Loading history...
31
use Symfony\Component\DependencyInjection\Loader\Configurator\ContainerConfigurator;
32
use Symplify\CodingStandard\Fixer\ArrayNotation\ArrayListItemNewlineFixer;
0 ignored issues
show
The type Symplify\CodingStandard\...rayListItemNewlineFixer was not found. Maybe you did not declare it correctly or list all dependencies?

The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g. excluded_paths: ["lib/*"], you can move it to the dependency path list as follows:

filter:
    dependency_paths: ["lib/*"]

For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths

Loading history...
33
use Symplify\CodingStandard\Fixer\ArrayNotation\ArrayOpenerAndCloserNewlineFixer;
0 ignored issues
show
The type Symplify\CodingStandard\...erAndCloserNewlineFixer was not found. Maybe you did not declare it correctly or list all dependencies?

The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g. excluded_paths: ["lib/*"], you can move it to the dependency path list as follows:

filter:
    dependency_paths: ["lib/*"]

For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths

Loading history...
34
use Symplify\CodingStandard\Fixer\Commenting\ParamReturnAndVarTagMalformsFixer;
0 ignored issues
show
The type Symplify\CodingStandard\...nAndVarTagMalformsFixer was not found. Maybe you did not declare it correctly or list all dependencies?

The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g. excluded_paths: ["lib/*"], you can move it to the dependency path list as follows:

filter:
    dependency_paths: ["lib/*"]

For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths

Loading history...
35
use Symplify\CodingStandard\Fixer\Strict\BlankLineAfterStrictTypesFixer;
0 ignored issues
show
The type Symplify\CodingStandard\...neAfterStrictTypesFixer was not found. Maybe you did not declare it correctly or list all dependencies?

The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g. excluded_paths: ["lib/*"], you can move it to the dependency path list as follows:

filter:
    dependency_paths: ["lib/*"]

For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths

Loading history...
36
37
return static function (ContainerConfigurator $containerConfigurator): void {
38
    $imports = [
39
        '/tools/04_ecs/vendor/symplify/easy-coding-standard/config/set/psr12.php',
40
        '/tools/04_ecs/vendor/symplify/easy-coding-standard/config/set/php70.php',
41
        '/tools/04_ecs/vendor/symplify/easy-coding-standard/config/set/php71.php',
42
        '/tools/04_ecs/vendor/symplify/easy-coding-standard/config/set/clean-code.php',
43
        '/tools/04_ecs/vendor/symplify/easy-coding-standard/config/set/common.php',
44
        '/tools/04_ecs/vendor/symplify/easy-coding-standard/config/set/symfony.php',
45
    ];
46
47
    array_map(
48
        [$containerConfigurator, 'import'],
49
        array_map(static fn (string $path): string => __DIR__ . $path, $imports)
50
    );
51
52
    $services = $containerConfigurator->services();
53
54
    $services
55
        ->set(IncrementStyleFixer::class)
56
        ->call(
57
            'configure',
58
            [
59
                [
60
                    'style' => 'post',
61
                ],
62
            ],
63
        );
64
65
    $services
66
        ->set(YodaStyleFixer::class)
67
        ->call(
68
            'configure',
69
            [
70
                [
71
                    'equal' => false,
72
                    'identical' => false,
73
                    'less_and_greater' => false,
74
                ],
75
            ],
76
        );
77
78
    $services
79
        ->set(ConcatSpaceFixer::class)
80
        ->call(
81
            'configure',
82
            [
83
                [
84
                    'spacing' => 'one',
85
                ],
86
            ],
87
        );
88
89
    $services
90
        ->set(CastSpacesFixer::class)
91
        ->call(
92
            'configure',
93
            [
94
                [
95
                    'space' => 'none',
96
                ],
97
            ],
98
        );
99
100
    $services
101
        ->set(OrderedImportsFixer::class)
102
        ->call(
103
            'configure',
104
            [
105
                [
106
                    'imports_order' => ['class', 'function', 'const'],
107
                ],
108
            ],
109
        );
110
111
    $services
112
        ->set(NoSuperfluousPhpdocTagsFixer::class)
113
        ->call(
114
            'configure',
115
            [
116
                [
117
                    'remove_inheritdoc' => false,
118
                    'allow_mixed' => true,
119
                    'allow_unused_params' => false,
120
                ],
121
            ],
122
        );
123
124
    $services
125
        ->set(DeclareEqualNormalizeFixer::class)
126
        ->call(
127
            'configure',
128
            [
129
                [
130
                    'space' => 'single',
131
                ],
132
            ],
133
        );
134
135
    $services
136
        ->set(BlankLineBeforeStatementFixer::class)
137
        ->call(
138
            'configure',
139
            [
140
                [
141
                    'statements' => ['continue', 'declare', 'return', 'throw', 'try'],
142
                ],
143
            ],
144
        );
145
146
    $services
147
        ->set(DuplicateSpacesSniff::class)
148
        ->property('ignoreSpacesInAnnotation', true);
149
150
    $parameters = $containerConfigurator->parameters();
151
152
    $parameters->set(
153
        'skip',
154
        [
155
            NoMultilineWhitespaceAroundDoubleArrowFixer::class => null,
156
            PhpdocNoPackageFixer::class => null,
157
            PhpdocSummaryFixer::class => null,
158
            PhpdocSeparationFixer::class => null,
159
            BlankLineAfterOpeningTagFixer::class => null,
160
            ClassAttributesSeparationFixer::class => null,
161
            NoBlankLinesBeforeNamespaceFixer::class => null,
162
            NotOperatorWithSuccessorSpaceFixer::class => null,
163
            SingleLineThrowFixer::class => null,
164
            BlankLineAfterStrictTypesFixer::class => null,
165
            ParamReturnAndVarTagMalformsFixer::class => null,
166
            ArrayOpenerAndCloserNewlineFixer::class => null,
167
            ArrayListItemNewlineFixer::class => null,
168
            PhpdocAlignFixer::class => null,
169
            UnusedParameterSniff::class => null,
170
        ]
171
    );
172
};
173