File tree Expand file tree Collapse file tree 3 files changed +181
-118
lines changed Expand file tree Collapse file tree 3 files changed +181
-118
lines changed Original file line number Diff line number Diff line change 1
1
#!/usr/bin/env php
2
2
<?php
3
-
4
- $ finder = Symfony \CS \Finder::create ()
5
- ->ignoreDotFiles (true )
6
- ->ignoreVCS (true )
7
- ->exclude ('app/config ' )
8
- ->exclude ('app/data ' )
9
- ->exclude ('app/Resources ' )
10
- ->exclude ('var ' )
11
- ->exclude ('vendor ' )
12
- ->exclude ('web/bundles ' )
13
- ->exclude ('web/css ' )
14
- ->exclude ('web/fonts ' )
15
- ->exclude ('web/js ' )
16
- ->notPath ('web/config.php ' )
17
- ->in (__DIR__ )
18
- ;
19
-
20
- return Symfony \CS \Config::create ()
21
- ->level (Symfony \CS \FixerInterface::SYMFONY_LEVEL )
22
- ->fixers ([
23
- '-psr0 ' , // Ignore Tests\ namespace prefix mismatch with tests/ directory
24
- 'ordered_use ' ,
25
- 'phpdoc_order ' ,
26
- 'short_array_syntax ' ,
3
+ return PhpCsFixer \Config::create ()
4
+ ->setRiskyAllowed (true )
5
+ ->setRules ([
6
+ '@Symfony ' => true ,
7
+ '@Symfony:risky ' => true ,
8
+ 'array_syntax ' => ['syntax ' => 'short ' ],
9
+ 'ordered_imports ' => true ,
10
+ 'phpdoc_order ' => true ,
27
11
])
28
- ->finder ($ finder )
12
+ ->setFinder (
13
+ PhpCsFixer \Finder::create ()
14
+ ->ignoreDotFiles (true )
15
+ ->ignoreVCS (true )
16
+ ->exclude ('app/config ' )
17
+ ->exclude ('app/data ' )
18
+ ->exclude ('app/Resources ' )
19
+ ->exclude ('var ' )
20
+ ->exclude ('vendor ' )
21
+ ->exclude ('web/bundles ' )
22
+ ->exclude ('web/css ' )
23
+ ->exclude ('web/fonts ' )
24
+ ->exclude ('web/js ' )
25
+ ->notPath ('web/config.php ' )
26
+ ->in (__DIR__ )
27
+ )
29
28
;
Original file line number Diff line number Diff line change 29
29
"white-october/pagerfanta-bundle" : " ^1.0"
30
30
},
31
31
"require-dev" : {
32
- "friendsofphp/php-cs-fixer" : " ^1.12 " ,
32
+ "friendsofphp/php-cs-fixer" : " ^2.0 " ,
33
33
"phpunit/phpunit" : " ^4.8 || ^5.0" ,
34
34
"sensio/generator-bundle" : " ^3.0" ,
35
35
"symfony/phpunit-bridge" : " ^3.0"
You can’t perform that action at this time.
0 commit comments