File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 22
33declare (strict_types=1 );
44
5- use PhpCsFixer \Config ;
65use PhpCsFixer \Finder ;
76use PhpCsFixer \Runner \Parallel \ParallelConfigFactory ;
7+ use Yiisoft \CodeStyle \ConfigBuilder ;
88
99$ finder = (new Finder ())->in ([
1010 __DIR__ . '/src ' ,
1111 __DIR__ . '/tests ' ,
1212]);
1313
14- return ( new Config () )
14+ return ConfigBuilder:: build ( )
1515 ->setRiskyAllowed (true )
1616 ->setParallelConfig (ParallelConfigFactory::detect ())
1717 ->setRules ([
18- '@PER-CS3.0 ' => true ,
19- 'no_unused_imports ' => true ,
20- 'no_extra_blank_lines ' => [
21- 'tokens ' => [
22- 'curly_brace_block ' ,
23- 'extra ' ,
24- ],
25- ],
26- 'ordered_class_elements ' => true ,
27- 'class_attributes_separation ' => ['elements ' => ['method ' => 'one ' ]],
28- 'declare_strict_types ' => true ,
29- 'native_function_invocation ' => true ,
30- 'native_constant_invocation ' => true ,
31- 'fully_qualified_strict_types ' => [
32- 'import_symbols ' => true
33- ],
34- 'global_namespace_import ' => [
35- 'import_classes ' => true ,
36- 'import_constants ' => true ,
37- 'import_functions ' => true ,
38- ],
18+ '@Yiisoft/Core ' => true ,
19+ '@Yiisoft/Core:risky ' => true ,
3920 ])
4021 ->setFinder ($ finder );
Original file line number Diff line number Diff line change 3131 "php" : " ^8.1"
3232 },
3333 "require-dev" : {
34- "friendsofphp/php-cs-fixer" : " ^3.89.1" ,
34+ "friendsofphp/php-cs-fixer" : " ^3.93" ,
35+ "yiisoft/code-style" : " ^1.0" ,
3536 "maglnet/composer-require-checker" : " ^4.7.1" ,
3637 "phpunit/phpunit" : " ^10.5.46" ,
3738 "rector/rector" : " ^2.0.16" ,
You can’t perform that action at this time.
0 commit comments