-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.php-cs-fixer.php
75 lines (72 loc) · 2.16 KB
/
.php-cs-fixer.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
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
<?php
$finder = PhpCsFixer\Finder::create()
->in(__DIR__)
->exclude([
'bootstrap/cache',
'node_modules',
'storage',
'vendor',
]);
$config = new PhpCsFixer\Config();
$config->setRiskyAllowed(true)
->setFinder($finder)
->setRules([
'@PHP80Migration' => true,
'@PHP80Migration:risky' => true,
'@PSR12' => true,
'@PSR12:risky' => true,
'@PhpCsFixer' => true,
'@PhpCsFixer:risky' => true,
'@Symfony:risky' => true,
'array_syntax' => [
'syntax' => 'short',
],
'binary_operator_spaces' => [
'default' => 'single_space',
'operators' => [
'=>' => 'align_single_space_minimal',
'=' => 'align_single_space_minimal',
],
],
'blank_line_after_opening_tag' => true,
'blank_line_before_statement' => true,
'concat_space' => [
'spacing' => 'one',
],
'global_namespace_import' => [
'import_classes' => true,
'import_constants' => false,
'import_functions' => false,
],
'increment_style' => [
'style' => 'post',
],
'multiline_whitespace_before_semicolons' => [
'strategy' => 'no_multi_line',
],
'native_function_invocation' => [
'include' => [],
],
'native_constant_invocation' => [
'fix_built_in' => false,
],
'no_null_property_initialization' => false,
'no_unused_imports' => true,
'phpdoc_align' => false,
'phpdoc_no_alias_tag' => false,
'phpdoc_order' => true,
'phpdoc_to_comment' => false,
'phpdoc_types_order' => [
'sort_algorithm' => 'none',
'null_adjustment' => 'always_last'
],
'phpdoc_summary' => false,
'phpdoc_var_annotation_correct_order' => true,
'random_api_migration' => true,
'self_accessor' => false,
'strict_comparison' => true,
'strict_param' => true,
'use_arrow_functions' => false,
'yoda_style' => false,
]);
return $config;