-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy path.php-cs-fixer.php
More file actions
26 lines (24 loc) · 883 Bytes
/
.php-cs-fixer.php
File metadata and controls
26 lines (24 loc) · 883 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
<?php
$finder = PhpCsFixer\Finder::create()
->in(__DIR__ . '/src')
->in(__DIR__ . '/tests');
return (new PhpCsFixer\Config())
->setRules([
'@PSR12' => true,
'array_indentation' => true,
'array_syntax' => ['syntax' => 'short'],
'binary_operator_spaces' => true,
'concat_space' => ['spacing' => 'one'],
'explicit_string_variable' => true,
'list_syntax' => ['syntax' => 'short'],
'method_chaining_indentation' => true,
'no_unused_imports' => true,
'no_spaces_around_offset' => true,
'no_whitespace_before_comma_in_array' => true,
'ordered_imports' => ['sort_algorithm' => 'alpha'],
'single_quote' => true,
'standardize_increment' => true,
'standardize_not_equals' => true,
'ternary_to_null_coalescing' => true,
])
->setFinder($finder);