|
1 | 1 | <?xml version="1.0"?> |
2 | 2 | <ruleset name="Neuralab"> |
3 | 3 | <description>a.neuralab.coding-standard</description> |
4 | | - |
5 | 4 | <rule ref="Neuralab-Silent"/> |
6 | 5 | <rule ref="WordPress-Core"> |
7 | 6 | <!-- Shorthand ternary operators are nice and we want to use them --> |
8 | | - <!-- see https://www.php.net/manual/en/control-structures.if.php#102060 --> |
9 | 7 | <exclude name="WordPress.PHP.DisallowShortTernary" /> |
10 | 8 | <!-- We prefer short --> |
11 | 9 | <exclude name="Generic.Arrays.DisallowShortArraySyntax" /> |
12 | 10 | </rule> |
13 | 11 | <rule ref="WordPress-Docs"> |
14 | | - <!-- Don't force file comments --> |
| 12 | + <!-- Don't force comments --> |
15 | 13 | <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" /> |
16 | 21 | <!-- Allow embedded php without semicolon --> |
17 | 22 | <exclude name="Squiz.PHP.EmbeddedPhp.NoSemicolon"/> |
18 | 23 | <!-- Don't force Yoda --> |
19 | 24 | <exclude name="WordPress.PHP.YodaConditions" /> |
20 | 25 | </rule> |
21 | 26 | <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 --> |
24 | 32 | <rule ref="Generic.Arrays.DisallowLongArraySyntax" /> |
25 | 33 | </ruleset> |
0 commit comments