forked from chriwo/TYPO3-Distribution
-
Notifications
You must be signed in to change notification settings - Fork 1
/
.php_cs.dist
86 lines (82 loc) · 3.24 KB
/
.php_cs.dist
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
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
<?php
$header = <<<'EOF'
This file is part of PHP CS Fixer.
(c) Fabien Potencier <fabien@symfony.com>
Dariusz Rumiński <dariusz.ruminski@gmail.com>
This source file is subject to the MIT license that is bundled
with this source code in the file LICENSE.
EOF;
return PhpCsFixer\Config::create()
->setRiskyAllowed(true)
->setRules([
'@PHP70Migration' => true,
'@Symfony' => true,
'@Symfony:risky' => false,
'@PSR2' => true,
'array_syntax' => ['syntax' => 'short'],
'binary_operator_spaces' => true,
'blank_line_after_namespace' => true,
'blank_line_after_opening_tag' => false,
'blank_line_before_return' => false,
'combine_consecutive_unsets' => true,
'concat_space' => ['spacing' => 'one'],
'function_typehint_space' => true,
'general_phpdoc_annotation_remove' => ['package', 'subpackage', 'expectedException', 'expectedExceptionMessage', 'expectedExceptionMessageRegExp'],
'hash_to_slash_comment' => true,
'heredoc_to_nowdoc' => true,
'list_syntax' => ['syntax' => 'long'],
'lowercase_cast' => true,
'semicolon_after_instruction' => true,
'short_scalar_cast' => true,
'single_blank_line_before_namespace' => false,
'single_quote' => true,
'strict_comparison' => true,
'strict_param' => true,
'method_separation' => true,
'native_function_casing' => true,
'new_with_braces' => true,
'no_alias_functions' => true,
'no_blank_lines_after_class_opening' => true,
'no_blank_lines_after_phpdoc' => true,
'no_blank_lines_before_namespace' => true,
'no_empty_comment' => true,
'no_empty_phpdoc' => true,
'no_empty_statement' => true,
'no_extra_consecutive_blank_lines' => ['break', 'continue', 'return', 'extra', 'throw', 'use', 'parenthesis_brace_block', 'square_brace_block', 'curly_brace_block'],
'no_short_echo_tag' => true,
'no_unreachable_default_argument_value' => true,
'no_unused_imports' => true,
'no_useless_else' => true,
'no_useless_return' => true,
'no_whitespace_in_blank_line' => true,
'ordered_class_elements' => true,
'ordered_imports' => true,
'php_unit_strict' => true,
'php_unit_test_class_requires_covers' => true,
'phpdoc_add_missing_param_annotation' => true,
'phpdoc_align' => [],
'phpdoc_no_empty_return' => false,
'phpdoc_no_package' => true,
'phpdoc_order' => true,
'phpdoc_scalar' => true,
'phpdoc_types' => true,
'phpdoc_separation' => false,
'phpdoc_single_line_var_spacing' => true,
'phpdoc_trim' => true,
'self_accessor' => true,
'short_scalar_cast' => true,
'standardize_not_equals' => true,
'ternary_operator_spaces' => true,
'trailing_comma_in_multiline_array' => true,
'whitespace_after_comma_in_array' => true,
])
->setFinder(
PhpCsFixer\Finder::create()
->in(__DIR__)
->exclude('Tests/Fixtures')
->exclude('doc')
->exclude('Documentation')
->exclude('Resources')
->notName('ext_emconf.php')
)
;