-
Notifications
You must be signed in to change notification settings - Fork 1
/
.php_cs
32 lines (30 loc) · 1.04 KB
/
.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
<?php
$rules = [
'@PSR2' => true,
'single_quote' => true,
'ordered_imports' => ['sortAlgorithm' => 'alpha'],
'visibility_required' => false,
'blank_line_after_opening_tag' => true,
'braces' => ['allow_single_line_closure' => true],
'compact_nullable_typehint' => true,
'concat_space' => ['spacing' => 'one'],
'declare_equal_normalize' => ['space' => 'none'],
'function_typehint_space' => true,
'method_argument_space' => ['on_multiline' => 'ensure_fully_multiline'],
'no_empty_statement' => true,
'no_leading_import_slash' => true,
'no_leading_namespace_whitespace' => true,
'no_whitespace_in_blank_line' => true,
'return_type_declaration' => ['space_before' => 'none'],
];
return (new PhpCsFixer\Config)
->setRules($rules)
->setFinder(
PhpCsFixer\Finder::create()
->in(__DIR__ . '/src')
->in(__DIR__ . '/tests')
->notName('README.md')
->notName('*.xml')
->notName('*.yml')
->notName('_ide_helper.php')
);