-
Notifications
You must be signed in to change notification settings - Fork 2
/
.php-cs-fixer.dist.php
41 lines (37 loc) · 1.11 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
<?php
use PhpCsFixer\Config;
$finder = PhpCsFixer\Finder::create()
->name('*.php')
->ignoreDotFiles(true)
->ignoreVCS(true)
->exclude(['vendor'])
->in(__DIR__)
;
$config = new Config();
return $config
->setRules([
'@PSR1' => true,
'@PSR12' => true,
'strict_param' => true,
'array_syntax' => ['syntax' => 'short'],
'blank_line_before_statement' => ['statements' => ['return', 'throw']],
'general_phpdoc_tag_rename' => ['replacements' => [
'inheritDocs' => 'inheritDoc',
'inheritdocs' => 'inheritDoc',
'inheritdoc' => 'inheritDoc',
]],
'no_superfluous_phpdoc_tags' => [
'allow_mixed' => true,
'allow_unused_params' => true,
],
'no_unneeded_curly_braces' => [
'namespaces' => true,
],
'phpdoc_types_order' => [
'null_adjustment' => 'always_last',
],
])
->setIndent(' ')
->setLineEnding("\n")
->setFinder($finder)
;