-
Notifications
You must be signed in to change notification settings - Fork 141
/
phpcs.xml
41 lines (38 loc) · 2.04 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
<?xml version="1.0"?>
<ruleset name="LearnPress ruleset">
<description>LearnPress rules for PHP_CodeSniffer</description>
<!-- <config name="installed_paths" value="vendor/wp-coding-standards/wpcs,vendor/phpcsstandards/phpcsutils"/>-->
<arg value="ps"/>
<arg name="extensions" value="php"/>
<file>./inc</file>
<file>./templates</file>
<file>./config</file>
<file>learnpress.php</file>
<exclude-pattern>*/inc/libraries/*</exclude-pattern>
<exclude-pattern>vendor/*</exclude-pattern>
<exclude-pattern>node_modules/*</exclude-pattern>
<exclude-pattern>tests/*</exclude-pattern>
<exclude-pattern>package.json</exclude-pattern>
<exclude-pattern>assets/*</exclude-pattern>
<exclude-pattern>languages/*</exclude-pattern>
<exclude-pattern>release/*</exclude-pattern>
<rule ref="WordPress-Core">
<exclude name="Universal.Arrays.DisallowShortArraySyntax" />
<exclude name="Universal.Operators.StrictComparisons.LooseNotEqual" />
<exclude name="Universal.Operators.StrictComparisons.LooseEqual" />
<exclude name="Generic.WhiteSpace.IncrementDecrementSpacing.SpaceAfterIncrement" />
<exclude name="WordPress.NamingConventions.ValidHookName.UseUnderscores" />
<exclude name="WordPress.WP.I18n.MissingTranslatorsComment" />
<exclude name="WordPress.PHP.YodaConditions.NotYoda" />
<exclude name="WordPress.PHP.StrictInArray.MissingTrueStrict" />
<exclude name="WordPress.NamingConventions.ValidVariableName.VariableNotSnakeCase" />
<exclude name="WordPress.NamingConventions.ValidHookName.NotLowercase" />
<!-- When need check security query mysql use default of WordPress, need open -->
<exclude name="WordPress.DB.PreparedSQL.NotPrepared" />
<exclude name="WordPress.DB.PreparedSQL.InterpolatedNotPrepared" />
<exclude name="WordPress.NamingConventions.ValidVariableName.UsedPropertyNotSnakeCase" />
<exclude name="WordPress.NamingConventions.ValidFunctionName.MethodNameInvalid" />
<exclude name="WordPress.Files.FileName.InvalidClassFileName" />
<exclude name="WordPress.Files.FileName.NotHyphenatedLowercase" />
</rule>
</ruleset>