|
| 1 | +<?php |
| 2 | + |
| 3 | +$finder = (new PhpCsFixer\Finder()) |
| 4 | + ->exclude('vendor') |
| 5 | + ->in(__DIR__); |
| 6 | + |
| 7 | +return (new PhpCsFixer\Config()) |
| 8 | + ->setRiskyAllowed(true) |
| 9 | + ->setUsingCache(true) |
| 10 | + ->setRules([ |
| 11 | + '@PSR2' => true, |
| 12 | + 'array_syntax' => ['syntax' => 'short'], |
| 13 | + 'blank_line_before_statement' => true, |
| 14 | + 'cast_spaces' => true, |
| 15 | + 'concat_space' => ['spacing' => 'one'], |
| 16 | + 'no_empty_statement' => true, |
| 17 | + 'no_extra_blank_lines' => true, |
| 18 | + 'no_leading_import_slash' => true, |
| 19 | + 'no_multiline_whitespace_around_double_arrow' => true, |
| 20 | + 'multiline_whitespace_before_semicolons' => false, |
| 21 | + 'no_trailing_comma_in_singleline_array' => true, |
| 22 | + 'no_unused_imports' => true, |
| 23 | + 'no_whitespace_in_blank_line' => true, |
| 24 | + 'object_operator_without_whitespace' => true, |
| 25 | + 'ordered_imports' => ['sort_algorithm' => 'length'], |
| 26 | + 'phpdoc_order' => true, |
| 27 | + 'phpdoc_separation' => false, |
| 28 | + 'phpdoc_summary' => true, |
| 29 | + 'space_after_semicolon' => true, |
| 30 | + 'standardize_not_equals' => true, |
| 31 | + 'ternary_to_null_coalescing' => true, |
| 32 | + 'trailing_comma_in_multiline' => true, |
| 33 | + ]) |
| 34 | + ->setFinder($finder); |
0 commit comments