File tree 3 files changed +10
-25
lines changed
3 files changed +10
-25
lines changed Original file line number Diff line number Diff line change 33
33
"friendsofphp/php-cs-fixer" : " ^3.0" ,
34
34
"monolog/monolog" : " ^1.24|^2.1" ,
35
35
"symfony/phpunit-bridge" : " ^4.4|^5.3|^6.0" ,
36
- "phpstan/phpstan" : " ^1.3 " ,
37
- "phpstan/phpstan-phpunit" : " ^1 .0" ,
38
- "rector/rector" : " ^0.15 .0"
36
+ "phpstan/phpstan" : " ^2.0 " ,
37
+ "phpstan/phpstan-phpunit" : " ^2 .0" ,
38
+ "rector/rector" : " ^2.0 .0"
39
39
},
40
40
"suggest" : {
41
41
"ext-tidy" : " Used to clean up given HTML and to avoid problems with bad HTML structure."
Original file line number Diff line number Diff line change @@ -8,8 +8,6 @@ parameters:
8
8
bootstrapFiles :
9
9
- vendor/bin/.phpunit/phpunit/vendor/autoload.php
10
10
11
- checkMissingIterableValueType : false
12
-
13
11
includes :
14
12
- vendor/phpstan/phpstan-phpunit/extension.neon
15
13
- vendor/phpstan/phpstan-phpunit/rules.neon
Original file line number Diff line number Diff line change 3
3
declare (strict_types=1 );
4
4
5
5
use Rector \Config \RectorConfig ;
6
- use Rector \Core \ValueObject \PhpVersion ;
7
6
use Rector \Set \ValueObject \LevelSetList ;
8
7
9
- return static function (RectorConfig $ rectorConfig ): void {
10
- // paths to refactor; solid alternative to CLI arguments
11
- $ rectorConfig ->paths ([
8
+ return RectorConfig::configure ()
9
+ ->withPaths ([
12
10
__DIR__ . '/src ' ,
13
11
__DIR__ . '/tests ' ,
14
- ]);
15
-
16
- // Path to phpstan with extensions, that PHPSTan in Rector uses to determine types
17
- $ rectorConfig ->phpstanConfig (__DIR__ . '/phpstan.neon ' );
18
-
19
- $ rectorConfig ->bootstrapFiles ([
12
+ ])
13
+ ->withBootstrapFiles ([
20
14
__DIR__ . '/vendor/bin/.phpunit/phpunit/vendor/autoload.php ' ,
21
15
__DIR__ . '/vendor/autoload.php ' ,
22
- ]);
23
-
24
- // Define what rule sets will be applied
25
- $ rectorConfig ->sets ([
26
- LevelSetList::UP_TO_PHP_74 ,
27
- ]);
28
-
29
- // is your PHP version different from the one your refactor to?
30
- $ rectorConfig ->phpVersion (PhpVersion::PHP_74 );
31
- };
16
+ ])
17
+ ->withSets ([LevelSetList::UP_TO_PHP_74 ])
18
+ ;
You can’t perform that action at this time.
0 commit comments