Skip to content
This repository was archived by the owner on Jul 7, 2025. It is now read-only.

Commit ee7874b

Browse files
Ignore NoCodeFound
1 parent bb33c26 commit ee7874b

File tree

1 file changed

+13
-5
lines changed

1 file changed

+13
-5
lines changed

Neuralab/ruleset.xml

Lines changed: 13 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,25 +1,33 @@
11
<?xml version="1.0"?>
22
<ruleset name="Neuralab">
33
<description>a.neuralab.coding-standard</description>
4-
54
<rule ref="Neuralab-Silent"/>
65
<rule ref="WordPress-Core">
76
<!-- Shorthand ternary operators are nice and we want to use them -->
8-
<!-- see https://www.php.net/manual/en/control-structures.if.php#102060 -->
97
<exclude name="WordPress.PHP.DisallowShortTernary" />
108
<!-- We prefer short -->
119
<exclude name="Generic.Arrays.DisallowShortArraySyntax" />
1210
</rule>
1311
<rule ref="WordPress-Docs">
14-
<!-- Don't force file comments -->
12+
<!-- Don't force comments -->
1513
<exclude name="Squiz.Commenting.FileComment"/>
14+
<exclude name="Squiz.Commenting.FunctionComment" />
15+
<exclude name="Squiz.Commenting.VariableComment" />
16+
<exclude name="Squiz.Commenting.ClassComment" />
17+
<!-- A useless rule forcing comment ending character to be punctuation -->
18+
<exclude name="Squiz.Commenting.InlineComment.InvalidEndChar" />
19+
<!-- A useless rule forcing short comments to start with capital letters -->
20+
<exclude name="Generic.Commenting.DocComment.ShortNotCapital" />
1621
<!-- Allow embedded php without semicolon -->
1722
<exclude name="Squiz.PHP.EmbeddedPhp.NoSemicolon"/>
1823
<!-- Don't force Yoda -->
1924
<exclude name="WordPress.PHP.YodaConditions" />
2025
</rule>
2126
<rule ref="WordPress-Extra"/>
22-
23-
<!-- We prefer short -->
27+
<!-- Disable errors for php files without php code inside -->
28+
<rule ref="Internal.NoCodeFound">
29+
<severity>0</severity>
30+
</rule>
31+
<!-- We prefer short arrays -->
2432
<rule ref="Generic.Arrays.DisallowLongArraySyntax" />
2533
</ruleset>

0 commit comments

Comments
 (0)