-
Notifications
You must be signed in to change notification settings - Fork 8
/
phpcs.xml
60 lines (56 loc) · 3.15 KB
/
phpcs.xml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
<?xml version="1.0"?>
<ruleset name="Optimole">
<description>Optimole rules for PHP_CodeSnifferr</description>
<ini name="error_reporting" value="E_ALL & ~E_DEPRECATED" />
<file>.</file>
<exclude-pattern>node_modules/*</exclude-pattern>
<exclude-pattern>vendor/*</exclude-pattern>
<exclude-pattern>tests/*</exclude-pattern>
<exclude-pattern>*index.php</exclude-pattern>
<exclude-pattern>Gruntfile.js</exclude-pattern>
<exclude-pattern>dist</exclude-pattern>
<exclude-pattern>cypress</exclude-pattern>
<exclude-pattern>dist/*</exclude-pattern>
<exclude-pattern>artifact/*</exclude-pattern>
<exclude-pattern>assets/*</exclude-pattern>
<arg name="extensions" value="php"/>
<!--<exclude-pattern>*</exclude-pattern>-->
<rule ref="WordPress-Core">
<exclude name="Squiz.Commenting.FileComment.SpacingAfterComment"/>
<exclude name="Generic.Files.LowercasedFilename"/>
<exclude name="Generic.NamingConventions.UpperCaseConstantName"/>
<exclude name="Generic.Formatting.MultipleStatementAlignment.IncorrectWarning"/>
<exclude name="Generic.Formatting.MultipleStatementAlignment.NotSameWarning"/>
<exclude name="Generic.Arrays.DisallowShortArraySyntax.Found"/>
<exclude name="Squiz.Commenting.FunctionComment.MissingParamTag"/>
<exclude name="Squiz.Commenting.InlineComment.InvalidEndChar"/>
<exclude name="Squiz.Commenting.InlineComment.NotCapital"/>
<exclude name="Squiz.Commenting.FileComment"/>
<exclude name="WordPress.PHP.YodaConditions.NotYoda"/>
<exclude name="Universal.Arrays.DisallowShortArraySyntax.Found"/>
<exclude name="Squiz.PHP.DisallowMultipleAssignments"/>
<exclude name="WordPress.NamingConvention.ValidVariableName.StringNotSnakeCase"/>
<exclude name="WordPress.NamingConventions.ValidVariableName.NotSnakeCase"/>
<exclude name="WordPress.NamingConventions.ValidFunctionName.MethodNameInvalid"/>
<exclude name="WordPress.NamingConventions.ValidVariableName.MemberNotSnakeCase"/>
<exclude name="WordPress.NamingConventions.ValidVariableName.NotSnakeCaseMemberVar"/>
<exclude name="WordPress.Arrays.MultipleStatementAlignment.DoubleArrowNotAligned"/>
<exclude name="WordPress.Files.FileName.InvalidClassFileName"/>
<exclude name="WordPress.Files.FileName.NotHyphenatedLowercase"/>
<exclude name="WordPress.Arrays.ArrayDeclarationSpacing"/>
<exclude name="WordPress.WhiteSpace.PrecisionAlignment.Found"/>
<exclude name="Squiz.PHP.CommentedOutCode"/>
<exclude name="WordPress.PHP.YodaConditions.NotYoda"/>
<exclude name="WordPress.WhiteSpace.PrecisionAlignment.Found"/>
<exclude name="Generic.Files.LineEndings"/>
<exclude name="Generic.Arrays.DisallowShortArraySyntax.Found"/>
<exclude name="PEAR.NamingConventions.ValidClassName.Invalid"/>
</rule>
<!-- Disallow long array syntax -->
<rule ref="Generic.Arrays.DisallowLongArraySyntax"/>
<rule ref="WordPress-Docs">
</rule>
<rule ref="Squiz.Commenting.FunctionComment.ScalarTypeHintMissing">
<severity>0</severity>
</rule>
</ruleset>