-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy pathphpcs.xml
More file actions
45 lines (37 loc) · 1.77 KB
/
phpcs.xml
File metadata and controls
45 lines (37 loc) · 1.77 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
<?xml version="1.0"?>
<!-- CONTRIBUTING.md explains how to use this file with PHP_CodeSniffer -->
<ruleset name="GreenhostStandard">
<description>Greenhost PHP coding standard</description>
<rule ref="PSR12">
<!-- Yii enforced deviations from PSR-2 -->
<exclude name="PSR1.Classes.ClassDeclaration.MissingNamespace"/>
<exclude name="PSR2.Classes.PropertyDeclaration.Underscore"/>
<!-- Greenhost endorsed deviations from PSR-2 or PSR-12-->
<exclude name="PSR2.Classes.ClassDeclaration.OpenBraceNewLine"/>
<exclude name="Squiz.Functions.MultiLineFunctionDeclaration.BraceOnSameLine"/>
<exclude name="PSR12.Classes.OpeningBraceSpace.Found"/>
<!-- exclude name="Generic.WhiteSpace.DisallowTabIndent"/ -->
</rule>
<!-- No blank lines after a functions opening brace: -->
<rule ref="Squiz.WhiteSpace.FunctionOpeningBraceSpace"/>
<!-- Enforce the function declaration opening brace on the same line: -->
<rule ref="Generic.Functions.OpeningFunctionBraceKernighanRitchie"/>
<!-- Enforce the class declaration opening brace on the same line: -->
<rule ref="Generic.Classes.OpeningBraceSameLine"/>
<!-- Enforce the short array notation: -->
<rule ref="Generic.Arrays.DisallowLongArraySyntax"/>
<!-- Some Code Analysis: -->
<rule ref="Generic.CodeAnalysis.UnusedFunctionParameter"/>
<rule ref="Generic.Commenting.DocComment"/>
<rule ref="Generic.Commenting.Fixme"/>
<rule ref="Generic.Commenting.Todo"/>
<rule ref="Generic.Metrics.CyclomaticComplexity"/>
<rule ref="Generic.Metrics.NestingLevel"/>
<rule ref="Generic.PHP.DeprecatedFunctions"/>
<rule ref="Generic.Files.LineLength">
<properties>
<property name="lineLimit" value="100"/>
<property name="absoluteLineLimit" value="120"/>
</properties>
</rule>
</ruleset>