|
| 1 | +<?php |
| 2 | + |
| 3 | +return PhpCsFixer\Config::create() |
| 4 | + ->setRules([ |
| 5 | + '@PSR2' => true, |
| 6 | + 'array_syntax' => ['syntax' => 'short'], |
| 7 | + 'combine_consecutive_unsets' => true, |
| 8 | + 'method_separation' => true, |
| 9 | + 'no_multiline_whitespace_before_semicolons' => true, |
| 10 | + 'single_quote' => true, |
| 11 | + |
| 12 | + 'binary_operator_spaces' => [ |
| 13 | + 'align_double_arrow' => false, |
| 14 | + 'align_equals' => false, |
| 15 | + ], |
| 16 | + // 'blank_line_after_opening_tag' => true, |
| 17 | + // 'blank_line_before_return' => true, |
| 18 | + 'braces' => [ |
| 19 | + 'allow_single_line_closure' => true, |
| 20 | + ], |
| 21 | + // 'cast_spaces' => true, |
| 22 | + // 'class_definition' => ['singleLine' => true], |
| 23 | + 'concat_space' => ['spacing' => 'none'], |
| 24 | + 'declare_equal_normalize' => true, |
| 25 | + 'function_typehint_space' => true, |
| 26 | + 'hash_to_slash_comment' => true, |
| 27 | + 'include' => true, |
| 28 | + 'lowercase_cast' => true, |
| 29 | + // 'native_function_casing' => true, |
| 30 | + // 'new_with_braces' => true, |
| 31 | + // 'no_blank_lines_after_class_opening' => true, |
| 32 | + // 'no_blank_lines_after_phpdoc' => true, |
| 33 | + // 'no_empty_comment' => true, |
| 34 | + // 'no_empty_phpdoc' => true, |
| 35 | + // 'no_empty_statement' => true, |
| 36 | + 'no_extra_consecutive_blank_lines' => [ |
| 37 | + 'curly_brace_block', |
| 38 | + 'extra', |
| 39 | + 'parenthesis_brace_block', |
| 40 | + 'square_brace_block', |
| 41 | + 'throw', |
| 42 | + 'use', |
| 43 | + ], |
| 44 | + // 'not_operator_with_space' => true, |
| 45 | + 'not_operator_with_successor_space' => true, |
| 46 | + // 'no_leading_import_slash' => true, |
| 47 | + // 'no_leading_namespace_whitespace' => true, |
| 48 | + // 'no_mixed_echo_print' => ['use' => 'echo'], |
| 49 | + 'no_multiline_whitespace_around_double_arrow' => true, |
| 50 | + // 'no_short_bool_cast' => true, |
| 51 | + // 'no_singleline_whitespace_before_semicolons' => true, |
| 52 | + 'no_spaces_around_offset' => true, |
| 53 | + // 'no_trailing_comma_in_list_call' => true, |
| 54 | + // 'no_trailing_comma_in_singleline_array' => true, |
| 55 | + // 'no_unneeded_control_parentheses' => true, |
| 56 | + 'no_unused_imports' => true, |
| 57 | + 'no_whitespace_before_comma_in_array' => true, |
| 58 | + 'no_whitespace_in_blank_line' => true, |
| 59 | + // 'normalize_index_brace' => true, |
| 60 | + 'object_operator_without_whitespace' => true, |
| 61 | + // 'php_unit_fqcn_annotation' => true, |
| 62 | + // 'phpdoc_align' => true, |
| 63 | + // 'phpdoc_annotation_without_dot' => true, |
| 64 | + // 'phpdoc_indent' => true, |
| 65 | + // 'phpdoc_inline_tag' => true, |
| 66 | + // 'phpdoc_no_access' => true, |
| 67 | + // 'phpdoc_no_alias_tag' => true, |
| 68 | + // 'phpdoc_no_empty_return' => true, |
| 69 | + // 'phpdoc_no_package' => true, |
| 70 | + // 'phpdoc_no_useless_inheritdoc' => true, |
| 71 | + // 'phpdoc_return_self_reference' => true, |
| 72 | + // 'phpdoc_scalar' => true, |
| 73 | + // 'phpdoc_separation' => true, |
| 74 | + // 'phpdoc_single_line_var_spacing' => true, |
| 75 | + // 'phpdoc_summary' => true, |
| 76 | + // 'phpdoc_to_comment' => true, |
| 77 | + // 'phpdoc_trim' => true, |
| 78 | + // 'phpdoc_types' => true, |
| 79 | + // 'phpdoc_var_without_name' => true, |
| 80 | + // 'pre_increment' => true, |
| 81 | + // 'return_type_declaration' => true, |
| 82 | + // 'self_accessor' => true, |
| 83 | + // 'short_scalar_cast' => true, |
| 84 | + 'single_blank_line_before_namespace' => true, |
| 85 | + // 'single_class_element_per_statement' => true, |
| 86 | + // 'space_after_semicolon' => true, |
| 87 | + // 'standardize_not_equals' => true, |
| 88 | + 'ternary_operator_spaces' => true, |
| 89 | + 'trailing_comma_in_multiline_array' => true, |
| 90 | + 'trim_array_spaces' => true, |
| 91 | + 'unary_operator_spaces' => true, |
| 92 | + 'whitespace_after_comma_in_array' => true, |
| 93 | + ]) |
| 94 | + //->setIndent("\t") |
| 95 | + ->setLineEnding("\n"); |
0 commit comments