-
Notifications
You must be signed in to change notification settings - Fork 459
/
Copy path.php_cs
39 lines (36 loc) · 1.28 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
33
34
35
36
37
38
39
<?php
$finder = PhpCsFixer\Finder::create()
->files()
->name('*.php')
->name('*.phpt')
->in('ieducar');
return PhpCsFixer\Config::create()
->setRules([
'@PSR2' => true,
// All items of the @param, @throws, @return, @var, and @type phpdoc
// tags must be aligned vertically.
'phpdoc_align' => [
'align' => 'vertical'
],
// Convert double quotes to single quotes for simple strings.
'single_quote' => [
'strings_containing_single_quote_chars' => true
],
// Group and seperate @phpdocs with empty lines.
'phpdoc_separation' => true,
// An empty line feed should precede a return statement.
'blank_line_before_return' => true,
// PHP arrays should use the PHP 5.4 short-syntax.
'array_syntax' => ['syntax' => 'short'],
// Remove trailing whitespace at the end of blank lines.
'no_whitespace_in_blank_line' => true,
// Removes extra empty lines.
'no_extra_consecutive_blank_lines' => true,
// Unused use statements must be removed.
'no_unused_imports' => true,
// Ordering use statements.
'ordered_imports' => [
'sort_algorithm' => 'alpha'
]
])
->setFinder($finder);