|
1 | 1 | <?php |
2 | 2 |
|
3 | | -$finder = Symfony\Component\Finder\Finder::create() |
4 | | - ->files() |
5 | | - ->in(__DIR__.'/src') |
6 | | - ->ignoreDotFiles(true) |
7 | | - ->ignoreVCS(true); |
| 3 | +$finder = PhpCsFixer\Finder::create() |
| 4 | + ->in(__DIR__.'/src') |
| 5 | + ->in(__DIR__.'/tests'); |
8 | 6 |
|
9 | | -return Symfony\CS\Config\Config::create() |
10 | | - ->setUsingCache(true) |
11 | | - ->level(Symfony\CS\FixerInterface::PSR2_LEVEL) |
12 | | - ->fixers([ |
13 | | - '-psr0', |
14 | | - 'align_double_arrow', |
15 | | - 'align_equals', |
16 | | - 'blankline_after_open_tag', |
17 | | - 'concat_without_spaces', |
18 | | - 'double_arrow_multiline_whitespaces', |
19 | | - 'duplicate_semicolon', |
20 | | - 'empty_return', |
21 | | - 'extra_empty_lines', |
22 | | - 'include', |
23 | | - 'join_function', |
24 | | - 'multiline_array_trailing_comma', |
25 | | - 'multiline_spaces_before_semicolon', |
26 | | - 'new_with_braces', |
27 | | - 'no_blank_lines_after_class_opening', |
28 | | - 'no_empty_lines_after_phpdocs', |
29 | | - 'object_operator', |
30 | | - 'operators_spaces', |
31 | | - 'phpdoc_indent', |
32 | | - 'phpdoc_inline_tag', |
33 | | - 'phpdoc_no_access', |
34 | | - '-phpdoc_no_empty_return', |
35 | | - 'phpdoc_no_package', |
36 | | - '-phpdoc_params', |
37 | | - 'phpdoc_scalar', |
38 | | - 'phpdoc_separation', |
39 | | - 'phpdoc_short_description', |
40 | | - 'phpdoc_to_comment', |
41 | | - 'phpdoc_trim', |
42 | | - 'phpdoc_type_to_var', |
43 | | - 'phpdoc_var_without_name', |
44 | | - 'remove_leading_slash_use', |
45 | | - 'remove_lines_between_uses', |
46 | | - 'short_array_syntax', |
47 | | - 'single_array_no_trailing_comma', |
48 | | - 'single_blank_line_before_namespace', |
49 | | - 'single_quote', |
50 | | - 'spaces_cast', |
51 | | - 'standardize_not_equal', |
52 | | - 'ternary_spaces', |
53 | | - 'trim_array_spaces', |
54 | | - 'unused_use', |
55 | | - 'whitespacy_lines', |
56 | | - 'visibility', |
57 | | - ]) |
58 | | - ->finder($finder); |
| 7 | +return PhpCsFixer\Config::create() |
| 8 | + ->setRiskyAllowed(false) |
| 9 | + ->setRules([ |
| 10 | + '@Symfony' => true, |
| 11 | + 'binary_operator_spaces' => ['align_double_arrow' => false, 'align_equals' => false], |
| 12 | + 'no_empty_comment' => false, |
| 13 | + 'no_extra_consecutive_blank_lines' => false, |
| 14 | + 'not_operator_with_successor_space' => true, |
| 15 | + 'ordered_imports' => ['sortAlgorithm' => 'length'], |
| 16 | + 'phpdoc_align' => false, |
| 17 | + 'phpdoc_no_empty_return' => false, |
| 18 | + 'phpdoc_order' => true, |
| 19 | + 'pre_increment' => false, |
| 20 | + 'yoda_style' => false, |
| 21 | + ]) |
| 22 | + ->setFinder($finder); |
0 commit comments