Skip to content
GitLab
Explore
Projects
Groups
Topics
Snippets
Projects
Groups
Topics
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Monday Factory
php-code-checker
Commits
ed5d6bfd
Commit
ed5d6bfd
authored
4 years ago
by
Martin Zeman
Browse files
Options
Download
Patches
Plain Diff
New updated rules (beta)
parent
4cf56f52
beta
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
ruleset.xml
+21
-74
ruleset.xml
with
21 additions
and
74 deletions
+21
-74
ruleset.xml
+
21
−
74
View file @
ed5d6bfd
<?xml version="1.0"?>
<ruleset
name=
"Monday Factory"
>
<description>
Monday Factory coding standards
</description>
<rule
ref=
"Generic.WhiteSpace.DisallowSpaceIndent"
/>
<rule
ref=
"Generic.PHP.LowerCaseConstant"
/>
<rule
ref=
"Generic.Arrays.DisallowLongArraySyntax"
/>
<rule
ref=
"Generic.CodeAnalysis.JumbledIncrementer"
/>
<rule
ref=
"Generic.CodeAnalysis.UnconditionalIfStatement"
/>
<rule
ref=
"Generic.CodeAnalysis.UnnecessaryFinalModifier"
/>
<rule
ref=
"Generic.Files.ByteOrderMark"
/>
<rule
ref=
"Generic.Files.EndFileNewline"
/>
<rule
ref=
"Generic.Files.LineEndings"
/>
...
...
@@ -16,101 +11,53 @@
<property
name=
"absoluteLineLimit"
value=
"160"
/>
</properties>
</rule>
<rule
ref=
"Generic.Formatting.DisallowMultipleStatements"
/>
<rule
ref=
"Generic.Formatting.SpaceAfterCast"
/>
<rule
ref=
"Generic.PHP.CharacterBeforePHPOpeningTag"
/>
<rule
ref=
"PSR2.ControlStructures.ElseIfDeclaration"
/>
<rule
ref=
"PSR2.Files.ClosingTag"
/>
<rule
ref=
"PSR2.Methods.MethodDeclaration"
/>
<rule
ref=
"PSR2.Namespaces.NamespaceDeclaration"
/>
<rule
ref=
"./vendor/consistence/coding-standard/Consistence/ruleset.xml"
>
<exclude
name=
"PSR1.Files.SideEffects.FoundWithSymbols"
/>
<exclude
name=
"Squiz.Commenting.FunctionComment.MissingParamTag"
/>
<exclude
name=
"PEAR.Formatting.MultiLineAssignment.EqualSignLine"
/>
<exclude
name=
"SlevomatCodingStandard.Namespaces.ReferenceUsedNamesOnly.PartialUse"
/>
<exclude
name=
"Squiz.Strings.DoubleQuoteUsage.ContainsVar"
/>
<exclude
name=
"Squiz.Operators.IncrementDecrementUsage.Found"
/>
<exclude
name=
"Squiz.WhiteSpace.FunctionSpacing.Before"
/>
</rule>
<rule
ref=
"Consistence.Exceptions.ExceptionDeclaration"
>
<properties>
<property
name=
"exceptionsDirectoryName"
value=
"Exception"
/>
</properties>
</rule>
<rule
ref=
"Squiz.WhiteSpace.FunctionSpacing"
>
<properties>
<property
name=
"spacingBeforeFirst"
value=
"1"
/>
<property
name=
"spacing"
value=
"2"
/>
<property
name=
"spacingAfterLast"
value=
"0"
/>
</properties>
</rule>
<rule
ref=
"./vendor/slevomat/coding-standard/SlevomatCodingStandard/ruleset.xml"
>
<exclude
name=
"SlevomatCodingStandard.C
lasses.ModernClassNameReference.ClassNameReferencedViaFunctionCall
"
/>
<exclude
name=
"SlevomatCodingStandard.C
lasses.SuperfluousAbstractClassNaming.SuperfluousPrefix
"
/>
<exclude
name=
"SlevomatCodingStandard.C
lasses.SuperfluousExceptionNaming.SuperfluousSuffix
"
/>
<exclude
name=
"SlevomatCodingStandard.ControlStructures.DisallowShortTernaryOperator
.DisallowedShortTernaryOperator
"
/>
<exclude
name=
"SlevomatCodingStandard.C
ommenting.DisallowOneLinePropertyDocComment.OneLinePropertyComment
"
/>
<exclude
name=
"SlevomatCodingStandard.C
ommenting.DocCommentSpacing.IncorrectLinesCountBetweenDifferentAnnotationsTypes
"
/>
<exclude
name=
"SlevomatCodingStandard.C
ontrolStructures.BlockControlStructureSpacing.IncorrectLinesCountAfterControlStructure
"
/>
<exclude
name=
"SlevomatCodingStandard.ControlStructures.DisallowShortTernaryOperator"
/>
<exclude
name=
"SlevomatCodingStandard.ControlStructures.EarlyExit.EarlyExitNotUsed"
/>
<exclude
name=
"SlevomatCodingStandard.ControlStructures.
NewWithoutParentheses.UselessParentheses
"
/>
<exclude
name=
"SlevomatCodingStandard.ControlStructures.
JumpStatementsSpacing.IncorrectLinesCountAfterLastControlStructure
"
/>
<exclude
name=
"SlevomatCodingStandard.ControlStructures.NewWithParentheses.MissingParentheses"
/>
<exclude
name=
"SlevomatCodingStandard.Co
mmenting.RequireOneLinePropertyDocComment.MultiLinePropertyComment
"
/>
<exclude
name=
"SlevomatCodingStandard.Co
ntrolStructures.RequireMultiLineTernaryOperator.MultiLineTernaryOperatorNotUsed
"
/>
<exclude
name=
"SlevomatCodingStandard.ControlStructures.RequireYodaComparison.RequiredYodaComparison"
/>
<exclude
name=
"SlevomatCodingStandard.Commenting.DocCommentSpacing.IncorrectLinesCountBetweenDifferentAnnotationsTypes"
/>
<exclude
name=
"SlevomatCodingStandard.Exceptions.ReferenceThrowableOnly"
/>
<exclude
name=
"SlevomatCodingStandard.Functions.StaticClosure.ClosureNotStatic"
/>
<exclude
name=
"SlevomatCodingStandard.Functions.UnusedParameter.UnusedParameter"
/>
<exclude
name=
"SlevomatCodingStandard.Files.TypeNameMatchesFileName"
/>
<exclude
name=
"SlevomatCodingStandard.Namespaces.FullyQualifiedClassNameAfterKeyword"
/>
<exclude
name=
"SlevomatCodingStandard.Namespaces.FullyQualifiedGlobalFunctions.NonFullyQualified"
/>
<exclude
name=
"SlevomatCodingStandard.Namespaces.FullyQualifiedClassNameInAnnotation"
/>
<exclude
name=
"SlevomatCodingStandard.Namespaces.FullyQualifiedClassNameInAnnotation.NonFullyQualifiedClassName"
/>
<exclude
name=
"SlevomatCodingStandard.Namespaces.FullyQualifiedExceptions"
/>
<exclude
name=
"SlevomatCodingStandard.Namespaces.UnusedUses.MismatchingCaseSensitivity"
/>
<exclude
name=
"SlevomatCodingStandard.Namespaces.UseOnlyWhitelistedNamespaces"
/>
<exclude
name=
"SlevomatCodingStandard.Namespaces.FullyQualifiedGlobalConstants.NonFullyQualified"
/>
<exclude
name=
"SlevomatCodingStandard.Namespaces.FullyQualifiedGlobalFunctions.NonFullyQualified"
/>
<exclude
name=
"SlevomatCodingStandard.Namespaces.UseOnlyWhitelistedNamespaces"
/>
<exclude
name=
"SlevomatCodingStandard.Namespaces.UseSpacing.IncorrectLinesCountBetweenDifferentTypeOfUse"
/>
<exclude
name=
"SlevomatCodingStandard.Numbers.DisallowNumericLiteralSeparator.DisallowedNumericLiteralSeparator"
/>
<exclude
name=
"SlevomatCodingStandard.Operators.DisallowIncrementAndDecrementOperators.DisallowedPostDecrementOperator"
/>
<exclude
name=
"SlevomatCodingStandard.Operators.DisallowIncrementAndDecrementOperators.DisallowedPostIncrementOperator"
/>
<exclude
name=
"SlevomatCodingStandard.Operators.DisallowIncrementAndDecrementOperators.DisallowedPreDecrementOperator"
/>
<exclude
name=
"SlevomatCodingStandard.Operators.DisallowIncrementAndDecrementOperators.DisallowedPreIncrementOperator"
/>
<exclude
name=
"SlevomatCodingStandard.TypeHints.DisallowMixedTypeHint.DisallowedMixedTypeHint"
/>
<exclude
name=
"SlevomatCodingStandard.TypeHints.NullTypeHintOnLastPosition.NullTypeHintNotOnLastPosition"
/>
<exclude
name=
"SlevomatCodingStandard.TypeHints.TypeHintDeclaration.MissingParameterTypeHint"
/>
<exclude
name=
"SlevomatCodingStandard.TypeHints.TypeHintDeclaration.MissingParameterTypeHint.WhitespaceBeforeColon"
/>
<exclude
name=
"SlevomatCodingStandard.TypeHints.UselessConstantTypeHint.UselessDocComment"
/>
<exclude
name=
"SlevomatCodingStandard.Types.EmptyLinesAroundTypeBraces.NoEmptyLineAfterOpeningBrace"
/>
<exclude
name=
"SlevomatCodingStandard.Types.EmptyLinesAroundTypeBraces.NoEmptyLineBeforeClosingBrace"
/>
</rule>
<rule
ref=
"SlevomatCodingStandard.Classes.UnusedPrivateElements"
>
<properties>
<property
name=
"alwaysUsedPropertiesAnnotations"
type=
"array"
value=
"@ORM\Column,@ORM\ManyToOne,@ORM\OneToMany,@ORM\ManyToMany,@ORM\JoinColumn"
/>
</properties>
</rule>
<rule
ref=
"SlevomatCodingStandard.Namespaces.UnusedUses"
>
<properties>
<property
name=
"searchAnnotations"
value=
"true"
/>
</properties>
</rule>
<rule
ref=
"SlevomatCodingStandard.
TypeHints.ReturnTypeHintSpacing
"
>
<rule
ref=
"SlevomatCodingStandard.
Files.TypeNameMatchesFileName
"
>
<properties>
<property
name=
"spacesCountBeforeColon"
value=
"0"
/>
<property
name=
"rootNamespaces"
type=
"array"
>
<element
key=
"app"
value=
"App"
/>
</property>
</properties>
</rule>
<rule
ref=
"SlevomatCodingStandard.TypeHints.DeclareStrictTypes"
>
<properties>
<property
name=
"newlinesCountBetweenOpenTagAndDeclare"
value=
"2"
/>
<property
name=
"linesCountAfterDeclare"
value=
"1"
/>
<property
name=
"spacesCountAroundEqualsSign"
value=
"0"
/>
</properties>
</rule>
<rule
ref=
"SlevomatCodingStandard.TypeHints.TypeHintDeclaration"
>
<properties>
<property
name=
"usefulAnnotations"
type=
"array"
value=
"@dataProvider,@todo,@throws"
/>
</properties>
</rule>
<rule
ref=
"SlevomatCodingStandard.Namespaces.ReferenceUsedNamesOnly"
>
<rule
ref=
"SlevomatCodingStandard.Classes.MethodSpacing"
>
<properties>
<property
name=
"allowFullyQualifiedGlobalClasses"
value=
"true"
/>
<property
name=
"allowFullyQualifiedGlobalFunctions"
value=
"true"
/>
<property
name=
"allowFullyQualifiedGlobalConstants"
value=
"true"
/>
<property
name=
"minLinesCount"
value=
"1"
/>
<property
name=
"maxLinesCount"
value=
"1"
/>
</properties>
</rule>
</ruleset>
This diff is collapsed.
Click to expand it.
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment
Menu
Explore
Projects
Groups
Topics
Snippets