|
1 | 1 | <?php |
2 | 2 |
|
| 3 | +/* |
| 4 | + * This file is part of the Symfony package. |
| 5 | + * |
| 6 | + * (c) Fabien Potencier <fabien@symfony.com> |
| 7 | + * |
| 8 | + * For the full copyright and license information, please view the LICENSE |
| 9 | + * file that was distributed with this source code. |
| 10 | + */ |
| 11 | + |
3 | 12 | $fileHeaderComment = <<<COMMENT |
4 | 13 | This file is part of the Symfony package. |
5 | 14 |
|
|
9 | 18 | file that was distributed with this source code. |
10 | 19 | COMMENT; |
11 | 20 |
|
12 | | -$finder = PhpCsFixer\Finder::create() |
13 | | - ->in(__DIR__) |
14 | | - ->exclude('config') |
15 | | - ->exclude('var') |
16 | | - ->exclude('public/bundles') |
17 | | - ->exclude('public/build') |
18 | | - // exclude files generated by Symfony Flex recipes |
19 | | - ->notPath('public/index.php') |
20 | | - ->notPath('importmap.php') |
21 | | -; |
22 | | - |
23 | 21 | return (new PhpCsFixer\Config()) |
| 22 | + ->setFinder( |
| 23 | + PhpCsFixer\Finder::create()->in(['src', 'tests'])->append([__FILE__]) |
| 24 | + ) |
24 | 25 | ->setRiskyAllowed(true) |
25 | 26 | ->setRules([ |
26 | 27 | '@Symfony' => true, |
27 | 28 | '@Symfony:risky' => true, |
28 | 29 | 'header_comment' => ['header' => $fileHeaderComment, 'separate' => 'both'], |
29 | | - 'linebreak_after_opening_tag' => true, |
30 | | - 'mb_str_functions' => true, |
31 | | - 'no_php4_constructor' => true, |
32 | | - 'no_unreachable_default_argument_value' => true, |
33 | 30 | 'no_useless_else' => true, |
34 | 31 | 'no_useless_return' => true, |
35 | 32 | 'php_unit_strict' => true, |
36 | | - 'phpdoc_order' => true, |
37 | 33 | 'strict_comparison' => true, |
38 | 34 | 'strict_param' => true, |
39 | | - 'blank_line_between_import_groups' => false, |
40 | 35 | ]) |
41 | | - ->setFinder($finder) |
42 | 36 | ->setCacheFile(__DIR__.'/var/.php-cs-fixer.cache') |
43 | 37 | ; |
0 commit comments