Skip to content

Commit c3ead8a

Browse files
✨ Add rules
1 parent 75aea81 commit c3ead8a

File tree

2 files changed

+21
-0
lines changed

2 files changed

+21
-0
lines changed

SymfonyCustom/ruleset.xml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -81,4 +81,7 @@
8181
</rule>
8282
<rule ref="Squiz.WhiteSpace.SemicolonSpacing"/>
8383
<rule ref="Generic.Arrays.DisallowLongArraySyntax"/>
84+
<rule ref="Generic.CodeAnalysis.EmptyPHPStatement"/>
85+
<rule ref="Squiz.WhiteSpace.LogicalOperatorSpacing"/>
86+
<rule ref="Squiz.WhiteSpace.CastSpacing"/>
8487
</ruleset>

docs/standards.md

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,12 @@ we do not respect this rule:
5353
<rule ref="Generic.Formatting.SpaceAfterCast"/>
5454
```
5555

56+
- Do not use space inside type casting
57+
58+
```
59+
<rule ref="Squiz.WhiteSpace.CastSpacing"/>
60+
```
61+
5662
- Use lowercase for PHP functions
5763

5864
```
@@ -104,6 +110,18 @@ we do not respect this rule:
104110
<rule ref="Generic.Arrays.DisallowLongArraySyntax"/>
105111
```
106112

113+
- Do not use empty php statement
114+
115+
```
116+
<rule ref="Generic.CodeAnalysis.EmptyPHPStatement"/>
117+
```
118+
119+
- Add a single space before and after logical operator
120+
121+
```
122+
<rule ref="Squiz.WhiteSpace.LogicalOperatorSpacing"/>
123+
```
124+
107125
### Custom
108126
- Some others checks are made about array (`=>` alignments and indentation)
109127

0 commit comments

Comments
 (0)