33
44 <description >A custom set of code standard rules to check for Inpsyde Codex.</description >
55
6+ <!-- TRUE, FALSE, NULL are constant, we write in uppercase. -->
7+ <rule ref =" Generic.PHP.UpperCaseConstant" />
8+
9+ <!-- Allow . in hook names -->
10+ <rule ref =" WordPress.NamingConventions.ValidHookName" >
11+ <properties >
12+ <property name =" additionalWordDelimiters" value =" ." />
13+ </properties >
14+ </rule >
15+
16+ <!-- Include the WordPress ruleset, with exclusions. -->
617 <rule ref =" WordPress" >
718
19+ <exclude name =" WordPress.PHP.YodaConditions" />
20+
821 <exclude name =" WordPress.Files.FileName" />
9- <exclude name =" WordPress.PHP.YodaConditions" />
1022
23+ <exclude name =" Generic.PHP.LowerCaseConstant" />
24+ <exclude name =" Generic.WhiteSpace.ScopeIndent.Incorrect" />
25+ <exclude name =" Generic.Commenting.DocComment.MissingShort" />
1126 <exclude name =" Generic.PHP.DisallowShortOpenTag" />
12- <exclude name =" Generic.PHP.LowerCaseConstant" />
13- <exclude name =" Generic.WhiteSpace.ScopeIndent.Incorrect" />
14- <exclude name =" Generic.Commenting.DocComment.MissingShort" />
1527
16- <exclude name =" PEAR.Functions.FunctionCallSignature" />
28+ <exclude name =" Squiz.Commenting.FileComment.MissingPackageTag" />
29+ <exclude name =" Squiz.Commenting.FileComment.Missing" />
1730
18- <!-- Remove spaces before types check. -->
19- <exclude name =" Squiz.Commenting.VariableComment.VarIndent" />
20- <exclude name =" Squiz.Commenting.FunctionComment.SpacingBeforeParamType" />
21- <exclude name =" Squiz.Commenting.FunctionComment.SpacingBeforeParams" />
31+ <exclude name =" PEAR.Functions.FunctionCallSignature" />
2232
23- <!-- no need for @package in files -->
24- <exclude name =" Squiz.Commenting.FileComment.MissingPackageTag" />
33+ <!-- Remove spaces before types check. -->
34+ <exclude name =" Squiz.Commenting.VariableComment.VarIndent" />
35+ <exclude name =" Squiz.Commenting.FunctionComment.SpacingBeforeParamType" />
36+ <exclude name =" Squiz.Commenting.FunctionComment.SpacingBeforeParams" />
2537
26- <!-- Exclude full stops on inline comment. -->
27- <exclude name =" Squiz.Commenting.InlineComment.InvalidEndChar" />
28- <exclude name =" Squiz.Commenting.FunctionComment.MissingParamComment" />
38+ <!-- Exclude Full Stops on inline comment. -->
39+ <exclude name =" Squiz.Commenting.InlineComment.InvalidEndChar" />
40+ <exclude name =" Squiz.Commenting.FunctionComment.MissingParamComment" />
2941
3042 <!-- Remove empty line not required before block comment -->
31- <exclude name =" Squiz.Commenting.BlockComment.HasEmptyLineBefore" />
43+ <exclude name =" Squiz.Commenting.BlockComment.HasEmptyLineBefore" />
3244 <!-- Remove rule for /** style for each var -->
33- <exclude name =" Squiz.Commenting.VariableComment.WrongStyle" />
34-
35- <exclude name =" WordPress.WhiteSpace.ScopeIndent.Incorrect" />
36- <exclude name =" WordPress.Arrays.ArrayKeySpacingRestrictions" />
37- <exclude name =" WordPress.Arrays.ArrayDeclaration.KeyNotAligned" />
45+ <exclude name =" Squiz.Commenting.VariableComment.WrongStyle" />
3846
47+ <!-- <exclude name="WordPress.XSS.EscapeOutput" /> -->
48+ <exclude name =" WordPress.WhiteSpace.ScopeIndent.Incorrect" />
49+ <exclude name =" WordPress.Arrays.ArrayKeySpacingRestrictions" />
50+ <exclude name =" WordPress.Arrays.ArrayDeclaration.KeyNotAligned" />
3951 <!-- Remove spaces instead of tabs check -->
40- <exclude name =" WordPress.Arrays.ArrayDeclaration.ValueNotAligned" />
41- <exclude name =" WordPress.Arrays.ArrayDeclaration.CloseBraceNotAligned" />
52+ <exclude name =" WordPress.Arrays.ArrayDeclaration.ValueNotAligned" />
53+ <exclude name =" WordPress.Arrays.ArrayDeclaration.CloseBraceNotAligned" />
54+ <!-- <exclude name="WordPress.Variables.GlobalVariables" /> -->
4255 </rule >
56+
4357</ruleset >
0 commit comments