-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathphpcs.xml
More file actions
64 lines (54 loc) · 2.08 KB
/
phpcs.xml
File metadata and controls
64 lines (54 loc) · 2.08 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
52
53
54
55
56
57
58
59
60
61
62
63
64
<?xml version="1.0"?>
<ruleset name="PPV Streaming Platform">
<description>Coding standards for PPV Streaming Platform</description>
<!-- Show progress and sniff codes -->
<arg value="p"/>
<arg value="s"/>
<arg name="colors"/>
<arg name="parallel" value="8"/>
<!-- Paths to check -->
<file>src</file>
<!-- Paths to ignore -->
<exclude-pattern>vendor/*</exclude-pattern>
<exclude-pattern>tests/*</exclude-pattern>
<exclude-pattern>database/*</exclude-pattern>
<!-- Rules -->
<rule ref="PSR12">
<!-- Allow longer lines for readability -->
<exclude name="Generic.Files.LineLength"/>
</rule>
<!-- Additional rules -->
<rule ref="Generic.PHP.ForbiddenFunctions">
<properties>
<property name="forbiddenFunctions" type="array">
<element key="eval" value="null"/>
<element key="exec" value="null"/>
<element key="shell_exec" value="null"/>
<element key="system" value="null"/>
<element key="passthru" value="null"/>
<element key="file_get_contents" value="Use proper HTTP client"/>
<element key="curl_exec" value="Use Guzzle HTTP client"/>
</property>
</properties>
</rule>
<!-- Security rules -->
<rule ref="Generic.PHP.DisallowShortOpenTag"/>
<rule ref="Generic.Files.ByteOrderMark"/>
<!-- Line length -->
<rule ref="Generic.Files.LineLength">
<properties>
<property name="lineLimit" value="120"/>
<property name="absoluteLineLimit" value="200"/>
</properties>
</rule>
<!-- Array formatting -->
<rule ref="Generic.Arrays.DisallowLongArraySyntax"/>
<!-- Documentation -->
<rule ref="Squiz.Commenting.ClassComment">
<exclude name="Squiz.Commenting.ClassComment.Missing"/>
</rule>
<rule ref="Squiz.Commenting.FunctionComment">
<exclude name="Squiz.Commenting.FunctionComment.Missing"/>
<exclude name="Squiz.Commenting.FunctionComment.MissingParamComment"/>
</rule>
</ruleset>