Skip to content

Commit c3699c7

Browse files
mikemeijerCopilot
andauthored
#6 - update ecs config (#9)
* #6 - update ecs config * Update packages/php-linting-rules/configs/ecs.php Co-authored-by: Copilot <[email protected]> --------- Co-authored-by: Copilot <[email protected]>
1 parent ab2ae30 commit c3699c7

File tree

1 file changed

+13
-4
lines changed

1 file changed

+13
-4
lines changed

configs/ecs.php

Lines changed: 13 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@
4242
->withConfiguredRule(SlevomatCodingStandard\Sniffs\Classes\EnumCaseSpacingSniff::class, ['minLinesCountBeforeWithComment' => 1, 'maxLinesCountBeforeWithComment' => 1, 'minLinesCountBeforeWithoutComment' => 0, 'maxLinesCountBeforeWithoutComment' => 0])
4343
->withConfiguredRule(SlevomatCodingStandard\Sniffs\Classes\MethodSpacingSniff::class, ['minLinesCount' => 1, 'maxLinesCount' => 1])
4444
->withConfiguredRule(SlevomatCodingStandard\Sniffs\Classes\ParentCallSpacingSniff::class, ['linesCountBefore' => 0, 'linesCountAfter' => 1])
45-
->withConfiguredRule(SlevomatCodingStandard\Sniffs\Classes\PropertySpacingSniff::class, ['minLinesCountBeforeWithComment' => 1, 'maxLinesCountBeforeWithComment' => 1, 'minLinesCountBeforeWithoutComment' => 0, 'maxLinesCountBeforeWithoutComment' => 0])
45+
->withConfiguredRule(SlevomatCodingStandard\Sniffs\Classes\PropertySpacingSniff::class, ['minLinesCountBeforeWithComment' => 1, 'maxLinesCountBeforeWithComment' => 1, 'minLinesCountBeforeWithoutComment' => 1, 'maxLinesCountBeforeWithoutComment' => 1])
4646
->withConfiguredRule(SlevomatCodingStandard\Sniffs\Classes\TraitUseSpacingSniff::class, ['linesCountBeforeFirstUse' => 0, 'linesCountBeforeFirstUseWhenFirstInClass' => 0, 'linesCountBetweenUses' => 0, 'linesCountAfterLastUse' => 1, 'linesCountAfterLastUseWhenLastInClass' => 0])
4747
->withConfiguredRule(SlevomatCodingStandard\Sniffs\Commenting\DocCommentSpacingSniff::class, ['linesCountBeforeFirstContent' => 0, 'linesCountBetweenDescriptionAndAnnotations' => 1, 'linesCountBetweenDifferentAnnotationsTypes' => 0, 'linesCountAfterLastContent' => 0])
4848
// ->withConfiguredRule(SlevomatCodingStandard\Sniffs\ControlStructures\BlockControlStructureSpacingSniff::class, ['linesCountBefore' => 1, 'linesCountBeforeFirst' => 1, 'linesCountAfter' => 1, 'linesCountAfterLast' => 1, 'controlStructures' => ['if', 'switch', 'for', 'foreach', 'while', 'do']])
@@ -329,18 +329,24 @@
329329
SlevomatCodingStandard\Sniffs\Variables\UnusedVariableSniff::class,
330330
])->withSkip([
331331
SlevomatCodingStandard\Sniffs\Functions\UnusedParameterSniff::class => [
332-
getcwd() . '/app/Traits',
333-
getcwd() . '/app/Policies',
334332
getcwd() . '/app/Models',
333+
getcwd() . '/app/Policies',
334+
getcwd() . '/app/Repositories/QuerySorts',
335+
getcwd() . '/app/Scopes',
336+
getcwd() . '/app/Traits',
337+
getcwd() . '/app/Data/Casts',
338+
getcwd() . '/app/Providers',
335339
],
336340
SlevomatCodingStandard\Sniffs\Functions\DisallowEmptyFunctionSniff::class => [
337341
getcwd() . '/app/Providers',
338342
],
339343
SlevomatCodingStandard\Sniffs\TypeHints\PropertyTypeHintSniff::class => [
344+
getcwd() . '/app/Console/Commands',
340345
getcwd() . '/app/Models',
341346
],
342347
SlevomatCodingStandard\Sniffs\TypeHints\ParameterTypeHintSniff::class => [
343-
getcwd() . '/app/Models',
348+
getcwd() . '/app/Data/Casts',
349+
getcwd() . '/app/Models/User/User.php',
344350
],
345351
PhpCsFixer\Fixer\ClassNotation\ClassAttributesSeparationFixer::class => [
346352
getcwd() . '/app/Models',
@@ -352,4 +358,7 @@
352358
getcwd() . '/database/seeders',
353359
getcwd() . '/database/migrations',
354360
],
361+
SlevomatCodingStandard\Sniffs\TypeHints\ReturnTypeHintSniff::class => [
362+
getcwd() . '/app/Models/User/User.php',
363+
],
355364
]);

0 commit comments

Comments
 (0)