|
| 1 | +<?php |
| 2 | + |
| 3 | +$finder = PhpCsFixer\Finder::create() |
| 4 | + ->in(['config', 'src', 'tests']); |
| 5 | + |
| 6 | +return PhpCsFixer\Config::create() |
| 7 | + ->setUsingCache(false) |
| 8 | + ->setFinder($finder) |
| 9 | + ->setRules([ |
| 10 | + 'psr0' => false, |
| 11 | + '@PSR2' => true, |
| 12 | + 'blank_line_after_namespace' => true, |
| 13 | + 'braces' => true, |
| 14 | + 'class_definition' => true, |
| 15 | + 'concat_space' => ['spacing' => 'none'], |
| 16 | + 'elseif' => true, |
| 17 | + 'function_declaration' => true, |
| 18 | + 'indentation_type' => true, |
| 19 | + 'line_ending' => true, |
| 20 | + 'lowercase_constants' => true, |
| 21 | + 'lowercase_keywords' => true, |
| 22 | + 'method_argument_space' => [ |
| 23 | + 'ensure_fully_multiline' => true, |
| 24 | + ], |
| 25 | + 'no_break_comment' => true, |
| 26 | + 'no_closing_tag' => true, |
| 27 | + 'no_spaces_after_function_name' => true, |
| 28 | + 'no_spaces_inside_parenthesis' => true, |
| 29 | + 'no_trailing_whitespace' => true, |
| 30 | + 'no_trailing_whitespace_in_comment' => true, |
| 31 | + 'single_blank_line_at_eof' => true, |
| 32 | + 'single_class_element_per_statement' => [ |
| 33 | + 'elements' => ['property'], |
| 34 | + ], |
| 35 | + 'single_import_per_statement' => true, |
| 36 | + 'single_line_after_imports' => true, |
| 37 | + 'switch_case_semicolon_to_colon' => true, |
| 38 | + 'switch_case_space' => true, |
| 39 | + 'visibility_required' => true, |
| 40 | + 'encoding' => true, |
| 41 | + 'full_opening_tag' => true, |
| 42 | + 'blank_line_before_return' => true, |
| 43 | + 'no_trailing_comma_in_singleline_array' => true, |
| 44 | + 'trailing_comma_in_multiline_array' => true, |
| 45 | + 'array_indentation' => true, |
| 46 | + 'binary_operator_spaces' => [ |
| 47 | + 'operators' => [ |
| 48 | + '=' => 'single_space', |
| 49 | + ], |
| 50 | + ], |
| 51 | + 'fully_qualified_strict_types' => true, |
| 52 | + 'void_return' => true, |
| 53 | + 'cast_spaces' => [ |
| 54 | + 'space' => 'single', |
| 55 | + ], |
| 56 | + 'not_operator_with_successor_space' => true, |
| 57 | + ]); |
0 commit comments