-
Notifications
You must be signed in to change notification settings - Fork 0
/
.php_cs
41 lines (37 loc) · 918 Bytes
/
.php_cs
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
<?php
use PhpCsFixer\Finder;
use PhpCsFixer\Config;
$finder = Finder::create()
->exclude('vendor')
->in(getcwd())
->name('*.php')
->ignoreDotFiles(true)
->ignoreVCS(true);
$rules = [
'@Symfony' => true,
'braces' => [
'allow_single_line_closure' => false,
],
'ordered_imports' => [
'sortAlgorithm' => 'length',
],
'ordered_class_elements' => true,
'phpdoc_order' => true,
'no_empty_comment' => false,
'phpdoc_to_comment' => false,
'no_extra_consecutive_blank_lines' => [
'tokens' => [
'curly_brace_block',
'parenthesis_brace_block',
'extra',
'throw',
'use',
],
],
'not_operator_with_successor_space' => true,
'concat_space' => ['spacing' => 'one'],
];
return Config::create()
->setFinder($finder)
->setRules($rules)
->setUsingCache(true);