Skip to content

Commit 8d19c3e

Browse files
committed
chore: update rules, update deprecated rules
1 parent 07fd54d commit 8d19c3e

1 file changed

Lines changed: 33 additions & 24 deletions

File tree

config/php/phpcsfixer.rules.yml

Lines changed: 33 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -33,11 +33,33 @@ parameters:
3333
- while
3434
- yield
3535
- yield_from
36-
braces:
37-
allow_single_line_closure: true
38-
position_after_functions_and_oop_constructs: next
39-
position_after_control_structures: same
40-
position_after_anonymous_constructs: same
36+
blank_lines_before_namespace: true
37+
38+
control_structure_braces: true
39+
curly_braces_position:
40+
allow_single_line_anonymous_functions: true
41+
allow_single_line_empty_anonymous_classes: true
42+
control_structure_continuation_position:
43+
position: same_line
44+
declare_parentheses: true
45+
statement_indentation: true
46+
no_multiple_statements_per_line: true
47+
# Differs from PSR12 but includes it.
48+
no_extra_blank_lines:
49+
tokens:
50+
- break
51+
- case
52+
- continue
53+
- curly_brace_block
54+
- default
55+
- extra
56+
- parenthesis_brace_block
57+
- return
58+
- square_brace_block
59+
- switch
60+
- throw
61+
- use
62+
- use_trait
4163
cast_spaces:
4264
space: single
4365
class_attributes_separation:
@@ -143,27 +165,10 @@ parameters:
143165
no_alternative_syntax: true
144166
no_binary_string: true
145167
no_blank_lines_after_phpdoc: true
146-
no_blank_lines_before_namespace: false
147168
no_closing_tag: true
148169
no_empty_comment: true
149170
no_empty_phpdoc: true
150171
no_empty_statement: true
151-
# Differs from PSR12 but includes it.
152-
no_extra_blank_lines:
153-
tokens:
154-
- break
155-
- case
156-
- continue
157-
- curly_brace_block
158-
- default
159-
- extra
160-
- parenthesis_brace_block
161-
- return
162-
- square_brace_block
163-
- switch
164-
- throw
165-
- use
166-
- use_trait
167172
no_homoglyph_names: true
168173
no_leading_namespace_whitespace: true
169174
no_mixed_echo_print:
@@ -185,7 +190,12 @@ parameters:
185190
allow_unused_params: false
186191
remove_inheritdoc: true
187192
no_trailing_comma_in_list_call: true
188-
no_trailing_comma_in_singleline_array: true
193+
no_trailing_comma_in_singleline:
194+
elements:
195+
- arguments
196+
- array_destructuring
197+
- array
198+
- group_import
189199
no_trailing_whitespace: true
190200
no_trailing_whitespace_in_comment: true
191201
no_unneeded_control_parentheses:
@@ -323,7 +333,6 @@ parameters:
323333
single_line_throw: false
324334
simple_to_complex_string_variable: true
325335
simplified_null_return: false
326-
single_blank_line_before_namespace: true
327336
single_line_comment_style:
328337
comment_types:
329338
- hash

0 commit comments

Comments
 (0)