forked from pradosoft/prado-composer-extension
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.php-cs-fixer.dist.php
44 lines (41 loc) · 1.23 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
<?php
$finder = PhpCsFixer\Finder::create()
->exclude('docs/')
->exclude('tests/')
->exclude('vendor/')
->in(__DIR__);
$config = new PhpCsFixer\Config();
$config
->setRiskyAllowed(true)
->setIndent("\t")
->setLineEnding("\n")
->setRules([
'@PSR2' => true,
'align_multiline_comment' => true,
'array_syntax' => ['syntax' => 'short'],
'binary_operator_spaces' => true,
'blank_line_after_namespace' => true,
'blank_line_after_opening_tag' => true,
'cast_spaces' => ['space' => 'single'],
'combine_nested_dirname' => true,
'concat_space' => ['spacing' => 'one'],
'dir_constant' => true,
'is_null' => true,
'list_syntax' => ['syntax' => 'short'],
'modernize_types_casting' => true,
'no_alias_functions' => true,
'no_null_property_initialization' => true,
'no_whitespace_before_comma_in_array' => true,
'phpdoc_add_missing_param_annotation' => ['only_untyped' => false],
'phpdoc_order' => true,
'phpdoc_scalar' => true,
'phpdoc_types_order' => true,
'psr_autoloading' => true,
'ternary_operator_spaces' => true,
'ternary_to_null_coalescing' => true,
'trim_array_spaces' => true,
'visibility_required' => true,
'whitespace_after_comma_in_array' => true,
])
->setFinder($finder);
return $config;