forked from fzaninotto/Faker
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.php-cs-fixer.php
42 lines (40 loc) · 1.47 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
<?php
$finder = PhpCsFixer\Finder::create()
->in(__DIR__.'/src')
->in(__DIR__.'/test');
return (new PhpCsFixer\Config())->setRules(
[
'@Symfony' => true,
'@Symfony:risky' => true,
'array_syntax' => ['syntax' => 'short'],
'function_declaration' => [
'closure_function_spacing' => 'none',
'closure_fn_spacing' => 'none',
],
'no_unreachable_default_argument_value' => false,
'braces' => ['allow_single_line_closure' => true],
'fopen_flags' => ['b_mode' => true],
'heredoc_to_nowdoc' => false,
'phpdoc_annotation_without_dot' => false,
'phpdoc_trim' => false,
'phpdoc_add_missing_param_annotation' => false,
'phpdoc_order' => true,
'phpdoc_to_comment' => false,
'single_line_comment_style' => true,
'ternary_to_null_coalescing' => true,
'echo_tag_syntax' => ['format' => 'long'],
'static_lambda' => true,
'global_namespace_import' => false,
'multiline_whitespace_before_semicolons' => true,
'linebreak_after_opening_tag' => true,
'combine_consecutive_unsets' => true,
'native_function_invocation' => [
'include' => [\PhpCsFixer\Fixer\FunctionNotation\NativeFunctionInvocationFixer::SET_INTERNAL],
'exclude' => ['sleep'],
'scope' => 'namespaced',
'strict' => true,
],
]
)
->setRiskyAllowed(true)
->setFinder($finder);