-
-
Notifications
You must be signed in to change notification settings - Fork 21
/
Copy pathrector.php
45 lines (37 loc) · 1.35 KB
/
rector.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
<?php
declare(strict_types=1);
return static function (Rector\Config\RectorConfig $rectorConfig): void {
$rectorConfig->parallel();
$rectorConfig->importNames();
$rectorConfig->phpVersion(\Rector\ValueObject\PhpVersion::PHP_81);
$rectorConfig->paths(
[
__DIR__ . '/src',
__DIR__ . '/tests',
],
);
$rectorConfig->sets(
[
\Rector\Set\ValueObject\SetList::PHP_84,
\Rector\Set\ValueObject\LevelSetList::UP_TO_PHP_84,
\Rector\Set\ValueObject\SetList::CODE_QUALITY,
\Rector\Set\ValueObject\SetList::CODING_STYLE,
\Rector\Set\ValueObject\SetList::TYPE_DECLARATION,
],
);
$rectorConfig::configure()->withConfiguredRule(
\Rector\CodeQuality\Rector\BooleanAnd\SimplifyEmptyArrayCheckRector::class,
[
'include_numeric_string_check' => false,
],
);
$rectorConfig->skip(
[
\Rector\CodingStyle\Rector\Property\SplitGroupedPropertiesRector::class,
\Rector\CodingStyle\Rector\Stmt\NewlineAfterStatementRector::class,
\Rector\Php73\Rector\String_\SensitiveHereNowDocRector::class,
\Rector\Php74\Rector\Closure\ClosureToArrowFunctionRector::class,
\Rector\Php81\Rector\Property\ReadOnlyPropertyRector::class,
],
);
};