File tree 3 files changed +38
-1
lines changed
3 files changed +38
-1
lines changed Original file line number Diff line number Diff line change 7
7
/puli.json
8
8
/box.json
9
9
/.puli
10
+ /.php_cs.cache
Original file line number Diff line number Diff line change
1
+ <?php
2
+
3
+ require_once __DIR__ .'/vendor/autoload.php ' ;
4
+
5
+ use SLLH \StyleCIBridge \ConfigBridge ;
6
+ use Symfony \CS \Fixer \Contrib \HeaderCommentFixer ;
7
+
8
+ $ header = <<<EOF
9
+ This file is part of the puli/cli package.
10
+
11
+ (c) Bernhard Schussek <[email protected] >
12
+
13
+ For the full copyright and license information, please view the LICENSE
14
+ file that was distributed with this source code.
15
+ EOF ;
16
+
17
+ // PHP-CS-Fixer 1.x
18
+ if (method_exists ('Symfony\CS\Fixer\Contrib\HeaderCommentFixer ' , 'getHeader ' )) {
19
+ HeaderCommentFixer::setHeader ($ header );
20
+ }
21
+
22
+ $ config = ConfigBridge::create ();
23
+ $ config ->setUsingCache (true );
24
+
25
+ // PHP-CS-Fixer 2.x
26
+ if (method_exists ($ config , 'setRules ' )) {
27
+ $ config
28
+ ->setRiskyAllowed (true )
29
+ ->setRules (array_merge ($ config ->getRules (), array (
30
+ 'header_comment ' => array ('header ' => $ header )
31
+ )))
32
+ ;
33
+ }
34
+
35
+ return $ config ;
Original file line number Diff line number Diff line change 25
25
"require-dev" : {
26
26
"phpunit/phpunit" : " ^4.6" ,
27
27
"sebastian/version" : " ^1.0.1" ,
28
- "symfony/filesystem" : " ^2.3|^3.0"
28
+ "symfony/filesystem" : " ^2.3|^3.0" ,
29
+ "sllh/php-cs-fixer-styleci-bridge" : " ^2.1"
29
30
},
30
31
"autoload" : {
31
32
"psr-4" : {
You can’t perform that action at this time.
0 commit comments