forked from BambooPayment/sdk_php
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.php-cs-fixer.php
45 lines (42 loc) · 2.13 KB
/
.php-cs-fixer.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
42
43
44
45
<?php
$finder = PhpCsFixer\Finder::create()
->in([__DIR__ . '/src'], [__DIR__ . '/tests'], [__DIR__ . '/examples']);
$config = new PhpCsFixer\Config();
return $config
->setRules(
[
'@PSR2' => true,
'array_syntax' => ['syntax' => 'short'],
'binary_operator_spaces' => [
'operators' => [
'=' => 'align',
'=>' => 'align',
],
],
'single_line_after_imports' => true,
'blank_line_before_statement' => true,
'cast_spaces' => true,
'concat_space' => ['spacing' => 'one'],
'no_singleline_whitespace_before_semicolons' => true,
'not_operator_with_space' => false,
'no_unused_imports' => true,
'phpdoc_align' => false,
'phpdoc_indent' => true,
'phpdoc_no_access' => true,
'phpdoc_no_alias_tag' => true,
'phpdoc_no_package' => true,
'phpdoc_scalar' => true,
'phpdoc_separation' => true,
'phpdoc_summary' => true,
'phpdoc_to_comment' => true,
'phpdoc_trim' => true,
'single_blank_line_at_eof' => true,
'ternary_operator_spaces' => true,
'ordered_imports' => [
'sort_algorithm' => 'alpha',
'imports_order' => ['const', 'class', 'function'],
],
'no_extra_blank_lines' => true,
'no_whitespace_in_blank_line' => true,
])
->setFinder($finder);