/
.php-cs-fixer.dist.php
33 lines (29 loc) · 1.08 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
<?php
declare(strict_types=1);
$finder = PhpCsFixer\Finder::create()
->in(__DIR__ . '/src')
->in(__DIR__ . '/tests');
$config = new PhpCsFixer\Config();
$config
->setRiskyAllowed(true)
->setRules([
'@Symfony' => true,
'@PHP71Migration:risky' => true,
'concat_space' => ['spacing' => 'one'],
'psr_autoloading' => false,
'array_syntax' => ['syntax' => 'short'],
'class_definition' => ['multi_line_extends_each_single_line' => true],
'no_useless_else' => true,
'ordered_imports' => ['sort_algorithm' => 'alpha'],
'phpdoc_add_missing_param_annotation' => ['only_untyped' => true],
'echo_tag_syntax' => true,
'list_syntax' => ['syntax' => 'short'],
'linebreak_after_opening_tag' => true,
'void_return' => false,
'phpdoc_summary' => false,
'multiline_whitespace_before_semicolons' => ['strategy' => 'new_line_for_chained_calls'],
'global_namespace_import' => true,
])
->setCacheFile(__DIR__ . '/.php_cs.cache')
->setFinder($finder);
return $config;