-
-
Notifications
You must be signed in to change notification settings - Fork 2
/
rector.php
46 lines (38 loc) · 1.3 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
46
<?php
declare(strict_types=1);
use Rector\Config\RectorConfig;
use Rector\Core\ValueObject\PhpVersion;
use Rector\Set\ValueObject\SetList;
use Rector\Symfony\Set\SymfonySetList;
return static function (RectorConfig $rectorConfig): void {
$rectorConfig->phpVersion(phpVersion: PhpVersion::PHP_80);
$rectorConfig->importNames();
$rectorConfig->importShortClasses();
$rectorConfig->parallel();
// $rectorConfig->symfonyContainerPhp(filePath: __DIR__ . 'var/cache/dev/App_KernelDevDebugContainer.php');
$rectorConfig->autoloadPaths(autoloadPaths: [
__DIR__ . '/vendor/autoload.php',
]);
$rectorConfig->paths(paths: [
__DIR__ . '/lib',
]);
$rectorConfig->skip(criteria: [
__DIR__ . '/vendor',
]);
$rectorConfig->sets(sets: [
// SetList::CODE_QUALITY,
// SetList::CODING_STYLE,
// SetList::DEAD_CODE,
// SetList::EARLY_RETURN,
SetList::PHP_80,
// SetList::PSR_4,
// SetList::PRIVATIZATION,
// SetList::TYPE_DECLARATION,
// SetList::TYPE_DECLARATION_STRICT,
// SymfonySetList::SYMFONY_STRICT,
// SymfonySetList::SYMFONY_44,
// SymfonySetList::SYMFONY_CODE_QUALITY,
// SymfonySetList::SYMFONY_CONSTRUCTOR_INJECTION,
#SymfonySetList::ANNOTATIONS_TO_ATTRIBUTES,
]);
};