-
Notifications
You must be signed in to change notification settings - Fork 0
/
phpcs.xml.dist
51 lines (45 loc) · 2.37 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
<?xml version="1.0"?>
<ruleset xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" name="PHP_CodeSniffer"
xsi:noNamespaceSchemaLocation="https://raw.githubusercontent.com/squizlabs/PHP_CodeSniffer/master/phpcs.xsd">
<description>The coding standard.</description>
<file>examples</file>
<file>src</file>
<file>tests</file>
<arg name="basepath" value="."/>
<arg name="colors"/>
<arg value="np"/>
<arg name="cache" value=".phpcs.cache"/>
<ini name="memory_limit" value="512M"/>
<!-- PSR12 -->
<rule ref="PSR12"/>
<rule ref="PSR1.Classes.ClassDeclaration.MissingNamespace">
<exclude-pattern>examples/*</exclude-pattern>
</rule>
<!-- Slevomat -->
<config name="installed_paths" value="../../slevomat/coding-standard"/>
<rule ref="SlevomatCodingStandard.TypeHints">
<exclude name="SlevomatCodingStandard.TypeHints.ParameterTypeHint.UselessAnnotation"/>
<exclude name="SlevomatCodingStandard.TypeHints.ReturnTypeHint.UselessAnnotation"/>
<exclude name="SlevomatCodingStandard.TypeHints.DisallowMixedTypeHint.DisallowedMixedTypeHint"/>
</rule>
<rule ref="SlevomatCodingStandard.TypeHints.DeclareStrictTypes">
<properties>
<property name="spacesCountAroundEqualsSign" value="0"/>
<property name="newlinesCountAfterDeclare" value="2"/>
<property name="newlinesCountBetweenOpenTagAndDeclare" value="2"/>
</properties>
</rule>
<rule ref="SlevomatCodingStandard.Arrays"/>
<rule ref="SlevomatCodingStandard.Classes">
<exclude name="SlevomatCodingStandard.Classes.EmptyLinesAroundClassBraces.NoEmptyLineAfterOpeningBrace"/>
<exclude name="SlevomatCodingStandard.Classes.EmptyLinesAroundClassBraces.NoEmptyLineBeforeClosingBrace"/>
<exclude name="SlevomatCodingStandard.Classes.SuperfluousInterfaceNaming"/>
<exclude name="SlevomatCodingStandard.Classes.SuperfluousExceptionNaming"/>
<exclude name="SlevomatCodingStandard.Classes.SuperfluousErrorNaming"/>
</rule>
<rule ref="SlevomatCodingStandard.Commenting">
<exclude name="SlevomatCodingStandard.Commenting.DisallowOneLinePropertyDocComment.OneLinePropertyComment"/>
<exclude name="SlevomatCodingStandard.Commenting.RequireOneLineDocComment"/>
</rule>
<rule ref="SlevomatCodingStandard.ControlStructures.NewWithParentheses"/>
</ruleset>