-
Notifications
You must be signed in to change notification settings - Fork 1
/
.php_cs.dist
69 lines (65 loc) · 2.23 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
<?php
$finder = PhpCsFixer\Finder::create()
->in(__DIR__ . '/src')
;
return PhpCsFixer\Config::create()
->setFinder($finder)
->setCacheFile(__DIR__ . '/.php_cs.cache')
/*
->setRiskyAllowed(true)
'@Symfony:risky' => true,
'@PHP70Migration:risky' => true,
'@PHP71Migration:risky' => true,
*/
->setRules([
'@Symfony' => true,
'@PHP56Migration' => true,
'@PHP70Migration' => true,
'@PHP71Migration' => true,
'combine_consecutive_unsets' => true,
'array_syntax' => [
'syntax' => 'short'
],
'list_syntax' => [
'syntax' => 'short'
],
'no_useless_else' => true,
'no_useless_return' => true,
'ordered_class_elements' => true,
'ordered_imports' => true,
'concat_space' => ['spacing' => 'one'],
'psr4' => true,
'strict_comparison' => true,
'strict_param' => true,
'phpdoc_align' => false,
'phpdoc_order' => true,
'phpdoc_separation' => false,
'phpdoc_to_comment' => false,
'phpdoc_add_missing_param_annotation' => [
'only_untyped' => false
],
'modernize_types_casting' => true,
'no_php4_constructor' => true,
'php_unit_construct' => true,
'php_unit_strict' => true,
'semicolon_after_instruction' => true,
'doctrine_annotation_braces' => [
'syntax' => 'with_braces'
],
'doctrine_annotation_indentation' => true,
'doctrine_annotation_spaces' => true,
'declare_strict_types' => false,
'phpdoc_types_order' => [
'null_adjustment' => 'always_last'
],
'void_return' => false,
'pre_increment' => false,
'yoda_style' => false,
/* это я ставил */
// это правило не отлючается походу, продолжает ставить заяпятые
'trailing_comma_in_multiline_array' => false,
// странное правило, в наглую заменяет все инкременты на pre форму, может так и код сломать.
'increment_style' => false,
'no_superfluous_elseif' => true
])
;