-
Notifications
You must be signed in to change notification settings - Fork 6
/
rector.php
39 lines (34 loc) · 1.79 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
<?php
declare(strict_types=1);
use Rector\Set\ValueObject\SetList;
use Rector\Config\RectorConfig;
return static function (RectorConfig $rectorConfigurator): void {
// Define what rule sets will be applied
$rectorConfigurator->import(SetList::PHP_52);
$rectorConfigurator->import(SetList::PHP_53);
$rectorConfigurator->import(SetList::PHP_54);
$rectorConfigurator->import(SetList::PHP_55);
$rectorConfigurator->import(SetList::PHP_56);
$rectorConfigurator->import(SetList::PHP_70);
$rectorConfigurator->import(SetList::PHP_71);
$rectorConfigurator->import(SetList::PHP_72);
$rectorConfigurator->import(SetList::PHP_73);
$rectorConfigurator->import(SetList::PHP_74);
$rectorConfigurator->import(SetList::PHP_80);
$rectorConfigurator->import(SetList::PHP_81);
$rectorConfigurator->import(SetList::DEAD_CODE);
$rectorConfigurator->import(SetList::TYPE_DECLARATION);
$skipables = [
// \Rector\CodeQuality\Rector\If_\ShortenElseIfRector::class,
// \Rector\CodingStyle\Rector\Catch_\CatchExceptionNameMatchingTypeRector::class,
// \Rector\CodingStyle\Rector\Encapsed\EncapsedStringsToSprintfRector::class,
// \Rector\CodingStyle\Rector\ClassMethod\UnSpreadOperatorRector::class,
// \Rector\DeadCode\Rector\ClassMethod\RemoveUselessParamTagRector::class,
// //\Rector\TypeDeclaration\Rector\ClassMethod\AddArrayReturnDocTypeRector::class,
// \Rector\DeadCode\Rector\ClassMethod\RemoveUselessReturnTagRector::class,
// \Rector\Php71\Rector\FuncCall\CountOnNullRector::class,
// //\Rector\TypeDeclaration\Rector\FunctionLike\ParamTypeDeclarationRector::class,
// \Rector\DeadCode\Rector\ClassMethod\RemoveUselessParamTagRector::class
];
$rectorConfigurator->skip($skipables);
};