ConLite/rector.php

36 Zeilen
907 B
PHP

2023-04-07 16:32:06 +00:00
<?php
2023-07-18 20:09:07 +00:00
declare(strict_types=1);
2023-04-07 16:32:06 +00:00
use Rector\Config\RectorConfig;
use Rector\Set\ValueObject\LevelSetList;
2023-07-18 20:09:07 +00:00
use Rector\Set\ValueObject\SetList;
2023-04-07 16:32:06 +00:00
return static function (RectorConfig $rectorConfig): void {
/*
$rectorConfig->autoloadPaths([
__DIR__ . '/conlite',
__DIR__ . '/conlib',
__DIR__ . '/setup',
]);
*/
$rectorConfig->bootstrapFiles([
__DIR__ . '/rector_cl_autoload.php',
]);
2023-04-07 16:32:06 +00:00
$rectorConfig->parallel();
$rectorConfig->paths([
2023-07-18 20:09:07 +00:00
__DIR__.'/conlite',
2023-04-07 16:32:06 +00:00
]);
$rectorConfig->skip([
__DIR__ . DIRECTORY_SEPARATOR . 'node_modules',
__DIR__ . DIRECTORY_SEPARATOR . 'var',
__DIR__ . DIRECTORY_SEPARATOR . 'vendor',
]);
$rectorConfig->importNames();
2023-07-18 20:09:07 +00:00
$rectorConfig->sets([
LevelSetList::UP_TO_PHP_80,
SetList::CODE_QUALITY,
SetList::DEAD_CODE,
SetList::NAMING,
]);
2023-04-07 16:32:06 +00:00
};