-
-
Notifications
You must be signed in to change notification settings - Fork 83
Expand file tree
/
Copy path.php-cs-fixer.php
More file actions
28 lines (25 loc) · 896 Bytes
/
.php-cs-fixer.php
File metadata and controls
28 lines (25 loc) · 896 Bytes
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
<?php
use PhpCsFixer\Config;
$finder = PhpCsFixer\Finder::create()
->exclude('CodeGeneration/Fixtures')
->in(__DIR__.'/src/');
return (new Config())
->setRules([
'@Symfony' => true,
'yoda_style' => ['equal' => false, 'identical' => false, 'less_and_greater' => false],
'concat_space' => ['spacing' => 'one'],
'declare_strict_types' => true,
'no_alias_functions' => true,
'not_operator_with_space' => true,
'return_type_declaration' => true,
'phpdoc_to_return_type' => true,
'binary_operator_spaces' => false,
'php_unit_method_casing' => ['case' => 'snake_case'],
'void_return' => true,
'ordered_imports' => [
'sort_algorithm' => 'alpha',
'imports_order' => ['const', 'class', 'function'],
],
])
->setRiskyAllowed(true)
->setFinder($finder);