|
12 | 12 | $basePath = __DIR__.'/../../'; |
13 | 13 | $paths = [ |
14 | 14 | $basePath.'ci', |
| 15 | + $basePath.'fixtures', |
15 | 16 | $basePath.'src', |
16 | 17 | $basePath.'tests', |
17 | 18 | ]; |
18 | 19 | $rectorConfig->paths($paths); |
19 | 20 |
|
| 21 | + $rectorConfig->cacheDirectory($basePath.'var/cache/rector/'); |
| 22 | + |
20 | 23 | $rectorConfig->parallel(); |
21 | 24 | $rectorConfig->phpstanConfig($basePath.'ci/phpstan/config.neon'); |
| 25 | + |
| 26 | + $rectorConfig->sets([ |
| 27 | + SetList::CODE_QUALITY, |
| 28 | + SetList::DEAD_CODE, |
| 29 | + SetList::EARLY_RETURN, |
| 30 | + SetList::NAMING, |
| 31 | + SetList::PHP_80, |
| 32 | + SetList::PHP_81, |
| 33 | + SetList::TYPE_DECLARATION, |
| 34 | + SetList::PRIVATIZATION, |
| 35 | + SetList::CODING_STYLE, |
| 36 | + DoctrineSetList::DOCTRINE_ORM_25, |
| 37 | + DoctrineSetList::DOCTRINE_CODE_QUALITY, |
| 38 | + LevelSetList::UP_TO_PHP_81, |
| 39 | + ]); |
| 40 | + |
22 | 41 | $rectorConfig->skip([ |
23 | 42 | RenamePropertyToMatchTypeRector::class, |
24 | 43 | ]); |
25 | | - $rectorConfig->importShortClasses(false); |
26 | | - $rectorConfig->importNames(false, false); // @todo Enable once Rector introduces better support for function imports. |
27 | | - |
28 | | - $rectorConfig->import(SetList::CODE_QUALITY); |
29 | | - $rectorConfig->import(SetList::DEAD_CODE); |
30 | | - $rectorConfig->import(SetList::EARLY_RETURN); |
31 | | - $rectorConfig->import(SetList::NAMING); |
32 | | - $rectorConfig->import(SetList::PHP_80); |
33 | | - $rectorConfig->import(SetList::PHP_81); |
34 | | - $rectorConfig->import(SetList::TYPE_DECLARATION); |
35 | 44 |
|
36 | | - $rectorConfig->import(DoctrineSetList::DOCTRINE_ORM_25); |
37 | | - $rectorConfig->import(DoctrineSetList::DOCTRINE_CODE_QUALITY); |
38 | | - |
39 | | - $rectorConfig->import(LevelSetList::UP_TO_PHP_81); |
| 45 | + $rectorConfig->importShortClasses(false); |
| 46 | + $rectorConfig->importNames(false, false); |
40 | 47 | }; |
0 commit comments