1- <?xml version =" 1.0" ?>
1+ <?xml version =" 1.0" encoding =" UTF-8" ?>
2+ <ruleset xmlns : xsi =" http://www.w3.org/2001/XMLSchema-instance" name =" PSR12" >
3+ <description >Coding standard.</description >
4+ <arg name =" tab-width" value =" 4" />
25
3- <ruleset name =" PHP Coding Standards" >
46
5- < description >PHP Coding Standards</ description >
7+ < rule ref = " PSR1 " / >
68
7- <rule ref =" Generic.NamingConventions.UpperCaseConstantName" />
8- <rule ref =" Generic.CodeAnalysis.UnusedFunctionParameter" />
9- <rule ref =" Generic.Strings.UnnecessaryStringConcat" />
10-
11- <rule ref =" PSR2" />
129
13- < exclude-pattern >node_modules</ exclude-pattern >
10+ < rule ref = " PSR12 " / >
1411
15- <exclude-pattern >vendor</exclude-pattern >
1612
17- <exclude-pattern >src/HTTPStatusCodeCollection.php</exclude-pattern >
18-
13+ <rule ref =" Generic.Classes.DuplicateClassName" />
14+
15+
16+ <rule ref =" Generic.CodeAnalysis.EmptyStatement" />
17+ <rule ref =" Generic.CodeAnalysis.ForLoopShouldBeWhileLoop" />
18+ <rule ref =" Generic.CodeAnalysis.ForLoopWithTestFunctionCall" />
19+ <rule ref =" Generic.CodeAnalysis.JumbledIncrementer" />
20+ <rule ref =" Generic.CodeAnalysis.UnconditionalIfStatement" />
21+ <rule ref =" Generic.CodeAnalysis.UnnecessaryFinalModifier" />
22+ <rule ref =" Generic.CodeAnalysis.UnusedFunctionParameter" />
23+ <rule ref =" Generic.CodeAnalysis.UselessOverridingMethod" />
24+
25+
26+ <rule ref =" Generic.Commenting.Todo" />
27+ <rule ref =" Generic.Commenting.Fixme" />
28+
29+
30+ <rule ref =" Generic.ControlStructures.InlineControlStructure" />
31+
32+
33+ <rule ref =" Generic.Files.ByteOrderMark" />
34+ <rule ref =" Generic.Files.LineEndings" >
35+ <properties >
36+ <property name =" eolChar" value =" \n" />
37+ </properties >
38+ </rule >
39+ <!-- <rule ref="Generic.Files.LineLength">
40+ <properties>
41+ <property name="lineLimit" value="90" />
42+ <property name="absoluteLineLimit" value="90" />
43+ </properties>
44+ </rule>-->
45+
46+
47+ <rule ref =" Generic.Formatting.DisallowMultipleStatements" />
48+ <rule ref =" Generic.Formatting.MultipleStatementAlignment" />
49+ <rule ref =" Generic.Formatting.SpaceAfterCast" />
50+
51+
52+ <rule ref =" Generic.Functions.CallTimePassByReference" />
53+ <rule ref =" Generic.Functions.FunctionCallArgumentSpacing" />
54+
55+
56+ <rule ref =" Generic.Metrics.CyclomaticComplexity" >
57+ <properties >
58+ <property name =" complexity" value =" 50" />
59+ <property name =" absoluteComplexity" value =" 100" />
60+ </properties >
61+ </rule >
62+ <rule ref =" Generic.Metrics.NestingLevel" >
63+ <properties >
64+ <property name =" nestingLevel" value =" 10" />
65+ <property name =" absoluteNestingLevel" value =" 30" />
66+ </properties >
67+ </rule >
68+
69+
70+ <rule ref =" Generic.NamingConventions.ConstructorName" />
71+
72+
73+ <rule ref =" Generic.PHP.DeprecatedFunctions" />
74+ <rule ref =" Generic.PHP.DisallowShortOpenTag" />
75+ <rule ref =" Generic.PHP.ForbiddenFunctions" />
76+ <rule ref =" Generic.PHP.LowerCaseConstant" />
77+ <rule ref =" Generic.PHP.LowerCaseKeyword" />
78+ <rule ref =" Generic.PHP.LowerCaseType" />
79+ <rule ref =" Generic.PHP.NoSilencedErrors" />
80+
81+
82+ <rule ref =" Generic.Strings.UnnecessaryStringConcat" />
83+
84+
85+ <rule ref =" Generic.WhiteSpace.DisallowTabIndent" />
86+ <rule ref =" Generic.WhiteSpace.IncrementDecrementSpacing" />
87+ <rule ref =" Generic.WhiteSpace.ScopeIndent" >
88+ <properties >
89+ <property name =" indent" value =" 4" />
90+ <property name =" tabIndent" value =" true" />
91+ </properties >
92+ </rule >
93+
94+
95+ <rule ref =" PEAR.Functions.ValidDefaultValue" />
96+
97+
98+ <rule ref =" PSR1.Classes.ClassDeclaration" />
99+ <rule ref =" PSR1.Files.SideEffects" />
100+
101+
102+ <rule ref =" PSR2.Classes.ClassDeclaration" />
103+ <rule ref =" PSR2.Classes.PropertyDeclaration" />
104+
105+
106+ <rule ref =" PSR2.ControlStructures.ControlStructureSpacing" />
107+ <rule ref =" PSR2.ControlStructures.ElseIfDeclaration" />
108+ <rule ref =" PSR2.ControlStructures.SwitchDeclaration" />
109+
110+
111+ <rule ref =" PSR2.Files.ClosingTag" />
112+ <rule ref =" PSR2.Files.EndFileNewline" />
113+
114+
115+ <rule ref =" PSR2.Methods.FunctionCallSignature" />
116+ <rule ref =" PSR2.Methods.FunctionCallSignature.OpeningIndent" >
117+ <severity >0</severity >
118+ </rule >
119+ <rule ref =" PSR2.Methods.FunctionCallSignature.SpaceAfterCloseBracket" >
120+ <severity >0</severity >
121+ </rule >
122+ <rule ref =" PSR2.Methods.FunctionClosingBrace" />
123+ <rule ref =" PSR2.Methods.MethodDeclaration" />
124+ <rule ref =" PSR2.Methods.MethodDeclaration.Underscore" >
125+ <type >error</type >
126+ <message >Method name "%s" must not be prefixed with an underscore to indicate visibility</message >
127+ </rule >
128+
129+
130+ <rule ref =" PSR2.Namespaces.NamespaceDeclaration" />
131+ <rule ref =" PSR2.Namespaces.UseDeclaration" />
132+
133+
134+ <rule ref =" Squiz.ControlStructures.ControlSignature" />
135+ <rule ref =" Squiz.ControlStructures.ForEachLoopDeclaration" />
136+ <rule ref =" Squiz.ControlStructures.ForEachLoopDeclaration.AsNotLower" >
137+ <severity >0</severity >
138+ </rule >
139+ <rule ref =" Squiz.ControlStructures.ForEachLoopDeclaration.SpaceAfterOpen" >
140+ <severity >0</severity >
141+ </rule >
142+ <rule ref =" Squiz.ControlStructures.ForEachLoopDeclaration.SpaceBeforeClose" >
143+ <severity >0</severity >
144+ </rule >
145+ <rule ref =" Squiz.ControlStructures.ForLoopDeclaration" >
146+ <properties >
147+ <property name =" ignoreNewlines" value =" true" />
148+ </properties >
149+ </rule >
150+ <rule ref =" Squiz.ControlStructures.ForLoopDeclaration.SpacingAfterOpen" >
151+ <severity >0</severity >
152+ </rule >
153+ <rule ref =" Squiz.ControlStructures.ForLoopDeclaration.SpacingBeforeClose" >
154+ <severity >0</severity >
155+ </rule >
156+ <rule ref =" Squiz.ControlStructures.LowercaseDeclaration" />
157+
158+
159+ <rule ref =" Squiz.Functions.FunctionDeclaration" />
160+ <rule ref =" Squiz.Functions.FunctionDeclarationArgumentSpacing" >
161+ <properties >
162+ <property name =" equalsSpacing" value =" 1" />
163+ </properties >
164+ </rule >
165+ <rule ref =" Squiz.Functions.LowercaseFunctionKeywords" />
166+ <rule ref =" Squiz.Functions.MultiLineFunctionDeclaration" />
167+
168+
169+ <rule ref =" Squiz.Scope.MethodScope" />
170+
171+
172+ <rule ref =" Squiz.WhiteSpace.CastSpacing" />
173+ <rule ref =" Squiz.WhiteSpace.ControlStructureSpacing.SpacingAfterOpen" />
174+ <rule ref =" Squiz.WhiteSpace.ControlStructureSpacing.SpacingBeforeClose" />
175+ <rule ref =" Squiz.WhiteSpace.ScopeClosingBrace" />
176+ <rule ref =" Squiz.WhiteSpace.ScopeKeywordSpacing" />
177+ <rule ref =" Squiz.WhiteSpace.SuperfluousWhitespace" />
178+ <rule ref =" Squiz.WhiteSpace.SuperfluousWhitespace.EmptyLines" >
179+ <severity >0</severity >
180+ </rule >
181+ <rule ref =" Squiz.WhiteSpace.SuperfluousWhitespace.EndFile" >
182+ <severity >0</severity >
183+ </rule >
184+ <rule ref =" Squiz.WhiteSpace.SuperfluousWhitespace.StartFile" >
185+ <severity >0</severity >
186+ </rule >
187+
188+
189+ <rule ref =" Zend.Files.ClosingTag" />
190+
191+
192+ <arg name =" colors" />
193+ <arg value =" spvnl" />
194+ <ini name =" memory_limit" value =" 128M" />
195+
196+
197+ <exclude-pattern >node_modules</exclude-pattern >
198+ <exclude-pattern >vendor</exclude-pattern >
19199</ruleset >
0 commit comments