-
Notifications
You must be signed in to change notification settings - Fork 27
Expand file tree
/
Copy pathphpcs.xml.dist
More file actions
51 lines (42 loc) · 2.03 KB
/
Copy pathphpcs.xml.dist
File metadata and controls
51 lines (42 loc) · 2.03 KB
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
<?xml version="1.0"?>
<ruleset name="BerlinDB Coding Standards">
<description>WordPress coding standards for BerlinDB source and tests.</description>
<arg name="extensions" value="php"/>
<arg name="basepath" value="./"/>
<arg name="parallel" value="20"/>
<arg value="ps"/>
<file>src</file>
<file>tests</file>
<exclude-pattern>/vendor/*</exclude-pattern>
<exclude-pattern>/.cache/*</exclude-pattern>
<rule ref="WordPress-Core">
<exclude name="WordPress.Files.FileName"/>
<exclude name="WordPress.NamingConventions.ValidVariableName.UsedPropertyNotSnakeCase"/>
<exclude name="Generic.CodeAnalysis.AssignmentInCondition"/>
<exclude name="Squiz.PHP.DisallowMultipleAssignments"/>
<exclude name="Generic.Commenting.DocComment.ShortNotCapital"/>
<exclude name="Generic.Commenting.DocComment.LongNotCapital"/>
<exclude name="Squiz.Commenting.FunctionComment"/>
<exclude name="Universal.NamingConventions.NoReservedKeywordParameterNames"/>
<!-- BerlinDB uses $arr[ 'key' ] with spaces inside brackets for readability. -->
<exclude name="WordPress.Arrays.ArrayKeySpacingRestrictions.SpacesAroundArrayKeys"/>
<!-- BerlinDB vertically aligns closing parentheses for readability. -->
<exclude name="PEAR.Functions.FunctionCallSignature.SpaceBeforeCloseBracket"/>
</rule>
<!-- BerlinDB intentionally aligns = signs across blank-line and comment boundaries.
Keep as warning only; set maxPadding high so extended cross-group alignment is allowed. -->
<rule ref="Generic.Formatting.MultipleStatementAlignment">
<properties>
<property name="maxPadding" value="1000000"/>
<property name="error" value="false"/>
</properties>
</rule>
<!-- Downgrade to warning; BerlinDB camelCase $queryVars property names are intentional. -->
<rule ref="WordPress.NamingConventions.ValidVariableName.VariableNotSnakeCase">
<type>warning</type>
</rule>
<!-- Multiple classes per file is acceptable in test spy/helper files. -->
<rule ref="Generic.Files.OneObjectStructurePerFile">
<exclude-pattern>tests/*</exclude-pattern>
</rule>
</ruleset>