From 8c061df9de7ba0b052e746bcab2a9efc75f84114 Mon Sep 17 00:00:00 2001 From: Sergei Predvoditelev Date: Wed, 22 Nov 2023 17:13:16 +0300 Subject: [PATCH] improve --- .github/workflows/rector.yml | 4 +++- composer.json | 2 +- rector.php | 7 +++++++ 3 files changed, 11 insertions(+), 2 deletions(-) diff --git a/.github/workflows/rector.yml b/.github/workflows/rector.yml index adacd735..bd79331d 100644 --- a/.github/workflows/rector.yml +++ b/.github/workflows/rector.yml @@ -14,8 +14,10 @@ name: rector jobs: rector: uses: yiisoft/actions/.github/workflows/rector.yml@master + secrets: + token: ${{ secrets.YIISOFT_GITHUB_TOKEN }} with: os: >- ['ubuntu-latest'] php: >- - ['8.0'] + ['8.2'] diff --git a/composer.json b/composer.json index 3cf9710f..be146626 100644 --- a/composer.json +++ b/composer.json @@ -38,7 +38,7 @@ "require-dev": { "maglnet/composer-require-checker": "^4.2", "phpunit/phpunit": "^9.5", - "rector/rector": "^0.14.3", + "rector/rector": "^0.18.10", "roave/infection-static-analysis-plugin": "^1.16", "spatie/phpunit-watcher": "^1.23", "yiisoft/yii-debug": "dev-master", diff --git a/rector.php b/rector.php index 63713ce9..c80d86e9 100644 --- a/rector.php +++ b/rector.php @@ -4,6 +4,8 @@ use Rector\CodeQuality\Rector\Class_\InlineConstructorDefaultToPropertyRector; use Rector\Config\RectorConfig; +use Rector\Php73\Rector\FuncCall\JsonThrowOnErrorRector; +use Rector\Php74\Rector\Closure\ClosureToArrowFunctionRector; use Rector\Set\ValueObject\LevelSetList; return static function (RectorConfig $rectorConfig): void { @@ -19,4 +21,9 @@ $rectorConfig->sets([ LevelSetList::UP_TO_PHP_80, ]); + + $rectorConfig->skip([ + ClosureToArrowFunctionRector::class, + JsonThrowOnErrorRector::class, + ]); };