forked from tighten/jigsaw
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.php-cs-fixer.php
50 lines (49 loc) · 1.64 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
46
47
48
49
50
<?php
return (new PhpCsFixer\Config)
->setFinder(PhpCsFixer\Finder::create()->in(__DIR__)->exclude('tests/snapshots'))
->setRiskyAllowed(true)
->setRules([
'@PSR2' => true,
'@Symfony' => true,
'align_multiline_comment' => [
'comment_type' => 'all_multiline',
],
'binary_operator_spaces' => [
'operators' => [
'|' => 'single_space', // Doesn't apply to union types
],
],
'blank_line_after_namespace' => true,
'blank_line_after_opening_tag' => true,
'blank_line_before_statement' => [
'statements' => ['return', 'throw'],
],
'concat_space' => [
'spacing' => 'one',
],
'get_class_to_class_keyword' => true,
'global_namespace_import' => [
'import_classes' => true,
],
'new_with_braces' => false,
'no_empty_comment' => false,
'no_useless_else' => true,
'not_operator_with_successor_space' => true,
'php_unit_method_casing' => false,
'phpdoc_annotation_without_dot' => false,
'phpdoc_to_comment' => [
'ignored_tags' => ['var'],
],
'phpdoc_separation' => [
'groups' => [
['test', 'group', 'dataProvider', 'doesNotPerformAssertions'],
],
],
'phpdoc_var_annotation_correct_order' => true,
'single_line_empty_body' => true,
'trailing_comma_in_multiline' => [
'after_heredoc' => true,
'elements' => ['arrays', 'arguments', 'parameters'],
],
'yoda_style' => false,
]);