-
Notifications
You must be signed in to change notification settings - Fork 0
/
phpcs.xml.dist
53 lines (43 loc) · 1.75 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
<?xml version="1.0" encoding="UTF-8"?>
<ruleset xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="vendor/squizlabs/php_codesniffer/phpcs.xsd"
name="PRTSymfony">
<description>The PRT/ Symfony coding standard.</description>
<file>src/</file>
<file>spec/</file>
<file>tests/</file>
<!-- Don't check migration, externally generated -->
<exclude-pattern>*/Migrations/*</exclude-pattern>
<arg name="basepath" value="."/>
<arg name="cache" value=".phpcs-cache"/>
<arg name="colors"/>
<arg name="extensions" value="php"/>
<!-- Symfony follows the standards defined in the PSR-0, PSR-1 and PSR-2 documents. -->
<!-- Include the whole PSR-2 standard -->
<rule ref="PSR2"/>
<!-- This is standard PSR-2 - but always good to have it clearly specified -->
<rule ref="Generic.Files.LineLength">
<properties>
<property name="lineLimit" value="120" />
</properties>
</rule>
<!-- Custom for PRT -->
<!-- Ensure no superfluous whitespace/ newlines -->
<rule ref="Squiz.WhiteSpace.SuperfluousWhitespace">
<properties>
<!-- doesn't matter if there are random whitespaces on empty lines -->
<property name="ignoreBlankLines" value="true" />
</properties>
</rule>
<rule ref="Squiz.WhiteSpace.SuperfluousWhitespace.EmptyLines">
<severity>5</severity>
</rule>
<!-- Use [] for arrays not new array() -->
<rule ref="Generic.Arrays.DisallowLongArraySyntax.Found">
<type>warning</type>
</rule>
<!-- Ignore camel case method name for PHPSpec -->
<rule ref="PSR1.Methods.CamelCapsMethodName">
<exclude-pattern>spec/*</exclude-pattern>
</rule>
</ruleset>