Skip to content

Commit 3dd4f41

Browse files
authored
Merge pull request #33627 from karyna-tsymbal-atwix/improvement/m2-33507-update-php-cs-fixer-3.0.0
`friendsofphp/php-cs-fixer` composer dependency has been updated
2 parents 1e281a2 + 78ed483 commit 3dd4f41

File tree

4 files changed

+102
-181
lines changed

4 files changed

+102
-181
lines changed

.gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,8 @@ atlassian*
3232
/package.json
3333
/.php_cs
3434
/.php_cs.cache
35+
/.php-cs-fixer.php
36+
/.php-cs-fixer.cache
3537
/grunt-config.json
3638
/pub/media/*.*
3739
!/pub/media/.htaccess

.php_cs.dist renamed to .php-cs-fixer.dist.php

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -21,20 +21,20 @@
2121
->exclude('setup/vendor')
2222
->exclude('var');
2323

24-
return PhpCsFixer\Config::create()
25-
->setFinder($finder)
24+
$config = new PhpCsFixer\Config();
25+
$config->setFinder($finder)
2626
->setRules([
2727
'@PSR2' => true,
2828
'array_syntax' => ['syntax' => 'short'],
2929
'concat_space' => ['spacing' => 'one'],
3030
'include' => true,
3131
'new_with_braces' => true,
3232
'no_empty_statement' => true,
33-
'no_extra_consecutive_blank_lines' => true,
33+
'no_extra_blank_lines' => true,
3434
'no_leading_import_slash' => true,
3535
'no_leading_namespace_whitespace' => true,
3636
'no_multiline_whitespace_around_double_arrow' => true,
37-
'no_multiline_whitespace_before_semicolons' => true,
37+
'multiline_whitespace_before_semicolons' => true,
3838
'no_singleline_whitespace_before_semicolons' => true,
3939
'no_trailing_comma_in_singleline_array' => true,
4040
'no_unused_imports' => true,
@@ -44,3 +44,4 @@
4444
'standardize_not_equals' => true,
4545
'ternary_operator_spaces' => true,
4646
]);
47+
return $config;

composer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,7 @@
8181
"require-dev": {
8282
"allure-framework/allure-phpunit": "~1.4",
8383
"dealerdirect/phpcodesniffer-composer-installer": "^0.7.0",
84-
"friendsofphp/php-cs-fixer": "~2.18.1",
84+
"friendsofphp/php-cs-fixer": "~3.0.0",
8585
"lusitanian/oauth": "~0.8.10",
8686
"magento/magento-coding-standard": "*",
8787
"magento/magento2-functional-testing-framework": "^3.0",

0 commit comments

Comments
 (0)