|
| 1 | +<?php |
| 2 | +return PhpCsFixer\Config::create() |
| 3 | + ->setRiskyAllowed(true) |
| 4 | + ->setRules([ |
| 5 | + '@PSR2' => true, |
| 6 | + 'array_syntax' => [ |
| 7 | + 'syntax' => 'long', |
| 8 | + ], |
| 9 | + 'binary_operator_spaces' => true, |
| 10 | + 'concat_space' => [ |
| 11 | + 'spacing' => 'one', |
| 12 | + ], |
| 13 | + 'function_typehint_space' => true, |
| 14 | + 'hash_to_slash_comment' => true, |
| 15 | + 'linebreak_after_opening_tag' => true, |
| 16 | + 'lowercase_cast' => true, |
| 17 | + 'method_separation' => true, |
| 18 | + 'native_function_casing' => true, |
| 19 | + 'new_with_braces' => true, |
| 20 | + 'no_alias_functions' => true, |
| 21 | + 'no_blank_lines_after_class_opening' => true, |
| 22 | + 'no_blank_lines_after_phpdoc' => true, |
| 23 | + 'no_blank_lines_before_namespace' => true, |
| 24 | + 'no_empty_comment' => true, |
| 25 | + 'no_empty_phpdoc' => true, |
| 26 | + 'no_empty_statement' => true, |
| 27 | + 'no_extra_consecutive_blank_lines' => [ |
| 28 | + 'continue', |
| 29 | + 'curly_brace_block', |
| 30 | + 'extra', |
| 31 | + 'parenthesis_brace_block', |
| 32 | + 'square_brace_block', |
| 33 | + 'throw', |
| 34 | + ], |
| 35 | + 'no_leading_import_slash' => true, |
| 36 | + 'no_leading_namespace_whitespace' => true, |
| 37 | + 'no_multiline_whitespace_around_double_arrow' => true, |
| 38 | + 'no_multiline_whitespace_before_semicolons' => true, |
| 39 | + 'no_short_bool_cast' => true, |
| 40 | + 'no_singleline_whitespace_before_semicolons' => true, |
| 41 | + 'no_trailing_comma_in_list_call' => true, |
| 42 | + 'no_trailing_comma_in_singleline_array' => true, |
| 43 | + 'no_unneeded_control_parentheses' => [ |
| 44 | + 'break', |
| 45 | + 'clone', |
| 46 | + 'continue', |
| 47 | + 'echo_print', |
| 48 | + 'return', |
| 49 | + 'switch_case', |
| 50 | + ], |
| 51 | + 'no_unreachable_default_argument_value' => true, |
| 52 | + 'no_unused_imports' => true, |
| 53 | + 'no_useless_else' => true, |
| 54 | + 'no_useless_return' => true, |
| 55 | + 'no_whitespace_before_comma_in_array' => true, |
| 56 | + 'no_whitespace_in_blank_line' => true, |
| 57 | + 'normalize_index_brace' => true, |
| 58 | + 'ordered_imports' => true, |
| 59 | + 'phpdoc_add_missing_param_annotation' => true, |
| 60 | + 'phpdoc_no_package' => true, |
| 61 | + 'phpdoc_order' => true, |
| 62 | + 'phpdoc_scalar' => true, |
| 63 | + 'phpdoc_types' => true, |
| 64 | + 'self_accessor' => true, |
| 65 | + 'short_scalar_cast' => true, |
| 66 | + 'single_quote' => true, |
| 67 | + 'standardize_not_equals' => true, |
| 68 | + 'ternary_operator_spaces' => true, |
| 69 | + 'trailing_comma_in_multiline_array' => true, |
| 70 | + 'whitespace_after_comma_in_array' => true, |
| 71 | + ]) |
| 72 | + ->setFinder( |
| 73 | + PhpCsFixer\Finder::create() |
| 74 | + ->in(__DIR__) |
| 75 | + ->exclude('.Build') |
| 76 | + ->notName('ext_emconf.php') |
| 77 | + ); |
0 commit comments