Skip to content

Commit 8400cd2

Browse files
committed
fixup! Add ECS
1 parent 5a13db2 commit 8400cd2

File tree

2 files changed

+7
-9
lines changed

2 files changed

+7
-9
lines changed

.github/workflows/coding-standard.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,3 +8,5 @@ jobs:
88
coding-standard:
99
name: Coding Standard
1010
uses: brick/coding-standard/.github/workflows/coding-standard.yml@main
11+
with:
12+
php-version: "8.2"

tools/ecs/ecs.php

Lines changed: 5 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,8 @@
33
declare(strict_types=1);
44

55
use PHP_CodeSniffer\Standards\Squiz\Sniffs\Commenting\FunctionCommentSniff;
6-
use PhpCsFixer\Fixer\Whitespace\MethodChainingIndentationFixer;
7-
use SlevomatCodingStandard\Sniffs\Namespaces\ReferenceUsedNamesOnlySniff;
6+
use PhpCsFixer\Fixer\ClassNotation\OrderedTypesFixer;
7+
use PhpCsFixer\Fixer\Phpdoc\PhpdocTypesOrderFixer;
88
use SlevomatCodingStandard\Sniffs\Namespaces\UseSpacingSniff;
99
use SlevomatCodingStandard\Sniffs\Whitespaces\DuplicateSpacesSniff;
1010
use Symplify\EasyCodingStandard\Config\ECSConfig;
@@ -26,13 +26,6 @@
2626

2727
// PHP-CS-Fixer
2828
$ecsConfig->skip([
29-
// Allows tree building method chaining syntax for better readability
30-
MethodChainingIndentationFixer::class => [$libRootPath . '/src/Parser/IsoParsers.php'],
31-
32-
// Allows microtime() to be called from class namespace so that it can be overridden
33-
// and its return value mocked in SystemClockTest
34-
ReferenceUsedNamesOnlySniff::class => [$libRootPath . '/src/Clock/SystemClock.php'],
35-
3629
// Only interested in FunctionCommentSniff.ParamCommentFullStop, excludes the rest
3730
FunctionCommentSniff::class . '.Missing' => null,
3831
FunctionCommentSniff::class . '.MissingReturn' => null,
@@ -50,5 +43,8 @@
5043
// Keep a line between same use types, spacing around uses is done in other fixers
5144
UseSpacingSniff::class . '.IncorrectLinesCountBeforeFirstUse' => null,
5245
UseSpacingSniff::class . '.IncorrectLinesCountAfterLastUse' => null,
46+
47+
OrderedTypesFixer::class => null,
48+
PhpdocTypesOrderFixer::class => null,
5349
]);
5450
};

0 commit comments

Comments
 (0)