File tree 5 files changed +23
-17
lines changed
5 files changed +23
-17
lines changed Original file line number Diff line number Diff line change 29
29
```
30
30
2. Add it to your ` ecs.php` file:
31
31
` ` ` php
32
- use CodelyTv\C odingStyle\C odelyRules ;
32
+ use CodelyTv\C odingStyle;
33
33
use Symplify\E asyCodingStandard\C onfig\E CSConfig;
34
34
35
35
return function (ECSConfig $ecsConfig ): void {
36
36
$ecsConfig -> paths([__DIR__ . ' /src' ,]);
37
37
38
- $ecsConfig -> sets([CodelyRules::CODING_STYLE ]);
38
+ $ecsConfig -> sets([CodingStyle::DEFAULT ]);
39
39
40
40
// Or this if you prefer to have the code aligned
41
- // $ecsConfig -> sets([CodelyRules::CODING_STYLE_ALIGNED ]);
41
+ // $ecsConfig -> sets([CodingStyle::ALIGNED ]);
42
42
};
43
43
` ` `
44
44
3. Execute it:
Original file line number Diff line number Diff line change 4
4
"type" : " library" ,
5
5
"keywords" : [" static analysis" , " code style" ],
6
6
"license" : " AGPL-3.0-or-later" ,
7
+ "authors" : [
8
+ {
9
+ "name" : " Codely" ,
10
+ "homepage" : " https://codely.com"
11
+ }
12
+ ],
7
13
"autoload" : {
8
14
"psr-4" : {
9
- "CodelyTv\\ CodingStyle \\ " : " src/"
15
+ "CodelyTv\\ " : " src/"
10
16
}
11
17
},
12
18
"require" : {
Original file line number Diff line number Diff line change 2
2
3
3
declare (strict_types=1 );
4
4
5
- use CodelyTv \CodingStyle \ CodelyRules ;
5
+ use CodelyTv \CodingStyle ;
6
6
use Symplify \EasyCodingStandard \Config \ECSConfig ;
7
7
8
8
return function (ECSConfig $ ecsConfig ): void {
9
9
$ ecsConfig ->paths ([__DIR__ . '/src ' ,]);
10
10
11
- $ ecsConfig ->sets ([CodelyRules:: CODING_STYLE ]);
11
+ $ ecsConfig ->sets ([CodingStyle:: DEFAULT ]);
12
12
};
Load Diff This file was deleted.
Original file line number Diff line number Diff line change
1
+ <?php
2
+
3
+ declare (strict_types=1 );
4
+
5
+ namespace CodelyTv ;
6
+
7
+ final class CodingStyle
8
+ {
9
+ public const DEFAULT = __DIR__ . '/coding_style.php ' ;
10
+ public const ALIGNED = __DIR__ . '/coding_style_aligned.php ' ;
11
+ }
You can’t perform that action at this time.
0 commit comments