-
-
Notifications
You must be signed in to change notification settings - Fork 1
/
.php_cs.dist
39 lines (36 loc) · 1.49 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
<?php
$header = trim('This code is licensed under the MIT License.'.substr(file_get_contents('LICENSE'), strlen('The MIT License')));
use PhpCsFixer\Fixer\Operator\BinaryOperatorSpacesFixer;
return PhpCsFixer\Config::create()
->setRiskyAllowed(true)
->setRules([
'@Symfony' => true,
'array_syntax' => ['syntax' => 'short'],
'declare_strict_types' => true,
'explicit_indirect_variable' => true,
'no_superfluous_elseif' => true,
'no_unreachable_default_argument_value' => true,
'no_useless_else' => true,
'no_useless_return' => true,
'ordered_class_elements' => false,
'non_printable_character' => true,
'ordered_imports' => true,
'php_unit_test_class_requires_covers' => true,
'phpdoc_add_missing_param_annotation' => true,
'phpdoc_order' => true,
'visibility_required' => true,
'header_comment' => ['header' => $header, 'separate' => 'bottom', 'location' => 'after_open', 'comment_type' => 'PHPDoc'],
'ternary_to_null_coalescing' => true,
'yoda_style' => null,
'phpdoc_to_comment' => false,
'binary_operator_spaces' => ['operators' => ['=>' => BinaryOperatorSpacesFixer::ALIGN]],
'php_unit_method_casing' => ['case' => 'snake_case'],
'strict_comparison' => true,
'native_function_invocation' => true,
'phpdoc_no_alias_tag' => false,
])
->setFinder(
PhpCsFixer\Finder::create()
->in(__DIR__)
)
;