-
-
Notifications
You must be signed in to change notification settings - Fork 36
/
phpcs.xml.dist
68 lines (55 loc) · 2.54 KB
/
phpcs.xml.dist
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
61
62
63
64
65
66
67
68
<?xml version="1.0"?>
<ruleset name="WP Crontrol">
<config name="testVersion" value="7.4-"/>
<config name="minimum_wp_version" value="5.9"/>
<arg name="extensions" value="php"/>
<exclude-pattern>/.github/*</exclude-pattern>
<exclude-pattern>/node_modules/*</exclude-pattern>
<exclude-pattern>/tests/*</exclude-pattern>
<exclude-pattern>/vendor/*</exclude-pattern>
<rule ref="WordPress-Extra">
<!-- Skip checks for naming and indentation: -->
<exclude name="WordPress.NamingConventions.ValidHookName.UseUnderscores" />
<exclude name="WordPress.Files.FileName" />
<exclude name="WordPress.Arrays.MultipleStatementAlignment.DoubleArrowNotAligned" />
<exclude name="Generic.Functions.FunctionCallArgumentSpacing.TooMuchSpaceAfterComma" />
<exclude name="Generic.Formatting.MultipleStatementAlignment.NotSameWarning" />
<exclude name="PEAR.Functions.FunctionCallSignature.CloseBracketLine" />
<exclude name="PEAR.Functions.FunctionCallSignature.ContentAfterOpenBracket" />
<exclude name="PEAR.Functions.FunctionCallSignature.MultipleArguments" />
<exclude name="Squiz.Commenting.InlineComment.InvalidEndChar" />
<exclude name="Squiz.Commenting.FileComment" />
<!-- False positives: -->
<exclude name="WordPress.Security.NonceVerification.Recommended" />
<exclude name="WordPress.WP.CronInterval.ChangeDetected" />
<!-- I'll fix this eventually: -->
<exclude name="WordPress.PHP.DontExtract.extract_extract" />
<!-- Exclude short description sniff so short `@var` notation can be used -->
<exclude name="Generic.Commenting.DocComment.MissingShort"/>
<!-- Use Yoda condition checks, you may or may not. -->
<exclude name="WordPress.PHP.YodaConditions.NotYoda"/>
</rule>
<!-- Ignore some rules for the tests -->
<rule ref="PHPCompatibility">
<exclude-pattern>/tests</exclude-pattern>
</rule>
<rule ref="PSR2.Methods.MethodDeclaration.Underscore">
<exclude-pattern>/tests/acceptance</exclude-pattern>
</rule>
<rule ref="Squiz.Commenting.FunctionComment.MissingParamTag">
<exclude-pattern>/tests/acceptance</exclude-pattern>
</rule>
<rule ref="WordPress.NamingConventions.ValidFunctionName.MethodNameInvalid">
<exclude-pattern>/tests/acceptance</exclude-pattern>
</rule>
<rule ref="WordPress.NamingConventions.ValidVariableName.VariableNotSnakeCase">
<exclude-pattern>/tests/acceptance</exclude-pattern>
</rule>
<rule ref="WordPress-Docs" />
<rule ref="WordPress.WP.I18n">
<properties>
<property name="text_domain" type="array" value="wp-crontrol"/>
</properties>
</rule>
<rule ref="PHPCompatibilityWP"/>
</ruleset>