|
15 | 15 | return (new PhpCsFixer\Config()) |
16 | 16 | ->setRules([ |
17 | 17 | '@PSR12' => true, |
18 | | - 'array_syntax' => ['syntax' => 'short'], |
19 | | - 'binary_operator_spaces' => [ |
20 | | - 'default' => 'single_space', |
21 | | - ], |
22 | | - 'blank_line_after_namespace' => true, |
23 | | - 'blank_line_after_opening_tag' => true, |
24 | | - 'blank_line_before_statement' => [ |
25 | | - 'statements' => ['return'], |
26 | | - ], |
27 | | - 'cast_spaces' => true, |
28 | | - 'class_attributes_separation' => [ |
29 | | - 'elements' => [ |
30 | | - 'method' => 'one', |
31 | | - ], |
32 | | - ], |
33 | | - 'concat_space' => [ |
34 | | - 'spacing' => 'one', |
35 | | - ], |
36 | 18 | 'declare_strict_types' => true, |
37 | | - 'function_typehint_space' => true, |
38 | | - 'lowercase_cast' => true, |
39 | | - 'lowercase_static_reference' => true, |
40 | | - 'magic_constant_casing' => true, |
41 | | - 'magic_method_casing' => true, |
42 | | - 'method_argument_space' => [ |
43 | | - 'on_multiline' => 'ensure_fully_multiline', |
44 | | - ], |
45 | | - 'native_function_casing' => true, |
46 | | - 'native_function_type_declaration_casing' => true, |
47 | | - 'no_blank_lines_after_class_opening' => true, |
48 | | - 'no_blank_lines_after_phpdoc' => true, |
49 | | - 'no_empty_comment' => true, |
50 | | - 'no_empty_phpdoc' => true, |
51 | | - 'no_empty_statement' => true, |
52 | | - 'no_extra_blank_lines' => [ |
53 | | - 'tokens' => [ |
54 | | - 'extra', |
55 | | - 'throw', |
56 | | - 'use', |
57 | | - ], |
58 | | - ], |
59 | | - 'no_leading_import_slash' => true, |
60 | | - 'no_leading_namespace_whitespace' => true, |
61 | | - 'no_mixed_echo_print' => [ |
62 | | - 'use' => 'echo', |
63 | | - ], |
64 | | - 'no_multiline_whitespace_around_double_arrow' => true, |
65 | | - 'no_short_bool_cast' => true, |
66 | | - 'no_singleline_whitespace_before_semicolons' => true, |
67 | | - 'no_spaces_around_offset' => true, |
68 | | - 'no_trailing_comma_in_singleline' => true, |
69 | | - 'no_unneeded_control_parentheses' => true, |
70 | | - 'no_unused_imports' => true, |
71 | | - 'no_whitespace_before_comma_in_array' => true, |
72 | | - 'no_whitespace_in_blank_line' => true, |
73 | | - 'normalize_index_brace' => true, |
74 | | - 'object_operator_without_whitespace' => true, |
75 | | - 'ordered_imports' => ['sort_algorithm' => 'alpha'], |
76 | | - 'phpdoc_indent' => true, |
77 | | - 'phpdoc_inline_tag_normalizer' => true, |
78 | | - 'phpdoc_no_access' => true, |
79 | | - 'phpdoc_no_package' => true, |
80 | | - 'phpdoc_no_useless_inheritdoc' => true, |
81 | | - 'phpdoc_scalar' => true, |
82 | | - 'phpdoc_single_line_var_spacing' => true, |
83 | | - 'phpdoc_summary' => true, |
84 | | - 'phpdoc_trim' => true, |
85 | | - 'phpdoc_types' => true, |
86 | | - 'phpdoc_var_without_name' => true, |
87 | | - 'return_type_declaration' => true, |
88 | | - 'short_scalar_cast' => true, |
89 | | - 'single_class_element_per_statement' => true, |
90 | | - 'single_line_comment_style' => [ |
91 | | - 'comment_types' => ['hash'], |
92 | | - ], |
93 | | - 'single_quote' => true, |
94 | | - 'space_after_semicolon' => [ |
95 | | - 'remove_in_empty_for_expressions' => true, |
96 | | - ], |
97 | | - 'standardize_not_equals' => true, |
98 | | - 'ternary_operator_spaces' => true, |
99 | | - 'trim_array_spaces' => true, |
100 | | - 'unary_operator_spaces' => true, |
101 | | - 'whitespace_after_comma_in_array' => true, |
102 | 19 | ]) |
103 | 20 | ->setFinder($finder) |
104 | 21 | ->setRiskyAllowed(true) |
|
0 commit comments