Skip to content

Commit 02a6067

Browse files
authored
Upgrade PHP-CS-Fixer to 3.x (#42)
1 parent ae547e4 commit 02a6067

File tree

4 files changed

+8
-10
lines changed

4 files changed

+8
-10
lines changed

.gitattributes

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,7 @@
22

33
.gitattributes export-ignore
44
.gitignore export-ignore
5-
.scrutinizer.yml export-ignore
6-
.travis.yml export-ignore
5+
.php-cs-fixer.dist.php export-ignore
76
CHANGELOG.md export-ignore
87
composer.lock export-ignore
98
phpunit.xml.dist export-ignore

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
.php-cs-fixer.php
12
composer.lock
23
vendor
34
*.cache

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

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,7 @@
1010
'syntax' => 'short',
1111
],
1212
'binary_operator_spaces' => [
13-
'align_double_arrow' => false,
14-
'align_equals' => false,
13+
'operators' => ['=' => null, '=>' => null],
1514
],
1615
'blank_line_after_namespace' => true,
1716
'blank_line_after_opening_tag' => true,
@@ -37,18 +36,18 @@
3736
'declare_strict_types' => true,
3837
'function_typehint_space' => true,
3938
'include' => true,
39+
'increment_style' => ['style' => 'pre'],
4040
'indentation_type' => true,
4141
'lowercase_cast' => true,
4242
'method_chaining_indentation' => true,
43-
'method_separation' => true,
4443
'multiline_comment_opening_closing' => true,
4544
'native_function_casing' => true,
4645
'new_with_braces' => true,
4746
'no_blank_lines_after_phpdoc' => true,
4847
'no_empty_comment' => true,
4948
'no_empty_phpdoc' => true,
5049
'no_empty_statement' => true,
51-
'no_extra_consecutive_blank_lines' => [
50+
'no_extra_blank_lines' => [
5251
'tokens' => [
5352
'curly_brace_block',
5453
'extra',
@@ -94,8 +93,7 @@
9493
'phpdoc_trim_consecutive_blank_line_separation' => true,
9594
'phpdoc_types' => true,
9695
'phpdoc_var_without_name' => true,
97-
'pre_increment' => true,
98-
'psr4' => true,
96+
'psr_autoloading' => true,
9997
'return_type_declaration' => true,
10098
'short_scalar_cast' => true,
10199
'single_blank_line_before_namespace' => true,
@@ -105,7 +103,7 @@
105103
'standardize_not_equals' => true,
106104
'ternary_operator_spaces' => true,
107105
'ternary_to_null_coalescing' => true,
108-
'trailing_comma_in_multiline_array' => true,
106+
'trailing_comma_in_multiline' => ['elements' => ['arrays']],
109107
'trim_array_spaces' => true,
110108
'unary_operator_spaces' => true,
111109
'whitespace_after_comma_in_array' => true,

composer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
"composer-runtime-api": "^2.0.0"
88
},
99
"require-dev": {
10-
"friendsofphp/php-cs-fixer": "^2.17",
10+
"friendsofphp/php-cs-fixer": "^3.2",
1111
"jean85/composer-provided-replaced-stub-package": "^1.0",
1212
"phpstan/phpstan": "^0.12.66",
1313
"phpunit/phpunit": "^7.5|^8.5|^9.4",

0 commit comments

Comments
 (0)