-
Notifications
You must be signed in to change notification settings - Fork 0
/
.php-cs-fixer.dist.php
53 lines (51 loc) · 1.93 KB
/
.php-cs-fixer.dist.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
<?php
$finder = (new PhpCsFixer\Finder())
->in(__DIR__)
->exclude('var')
->exclude('build')
->exclude('vendor')
;
return (new PhpCsFixer\Config())
->setRules([
'@DoctrineAnnotation' => true,
'@PHP81Migration' => true,
'@Symfony' => true,
'align_multiline_comment' => true,
'array_indentation' => true,
'blank_line_before_statement' => [
'statements' => ['break', 'continue', 'return', 'throw', 'yield'],
],
'combine_consecutive_issets' => true,
'combine_consecutive_unsets' => true,
'concat_space' => ['spacing' => 'one'],
'control_structure_continuation_position' => true,
'declare_equal_normalize' => true,
'declare_strict_types' => true,
'function_declaration' => ['closure_function_spacing' => 'none'],
'global_namespace_import' => true,
'implode_call' => true,
'is_null' => true,
'method_chaining_indentation' => true,
'modernize_types_casting' => true,
'multiline_whitespace_before_semicolons' => ['strategy' => 'new_line_for_chained_calls'],
'no_superfluous_elseif' => true,
'no_useless_else' => true,
'no_useless_return' => true,
'nullable_type_declaration_for_default_null_value' => true,
'operator_linebreak' => true,
'phpdoc_align' => ['align' => 'left'],
'phpdoc_line_span' => ['property' => 'single'],
'phpdoc_order' => true,
'phpdoc_summary' => false,
'phpdoc_to_comment' => false,
'psr_autoloading' => true,
'return_assignment' => true,
'simplified_if_return' => true,
'simplified_null_return' => true,
'single_line_throw' => false,
'trailing_comma_in_multiline' => ['after_heredoc' => true, 'elements' => ['arrays', 'arguments', 'parameters']],
'yoda_style' => false,
])
->setRiskyAllowed(true)
->setFinder($finder)
;