Skip to content

Instantly share code, notes, and snippets.

@insekticid
Created July 25, 2017 07:25
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save insekticid/c5cfa9ab28a39099b6f727bfd7afec2c to your computer and use it in GitHub Desktop.
Save insekticid/c5cfa9ab28a39099b6f727bfd7afec2c to your computer and use it in GitHub Desktop.
Custom Symfony 4 Flex PHP 7.1 strict_types=1 coding standard
<?xml version="1.0"?>
<ruleset name="Exploit.cz">
<exclude-pattern>src/Kernel.php</exclude-pattern>
<rule ref="vendor/escapestudios/symfony2-coding-standard/Symfony/ruleset.xml">
<exclude name="Symfony.WhiteSpace.AssignmentSpacing"/>
<exclude name="Symfony.Commenting.ClassComment"/>
<exclude name="Symfony.Commenting.FunctionComment"/>
<exclude name="Squiz.Commenting.FunctionComment"/>
</rule>
<rule ref="vendor/slevomat/coding-standard/SlevomatCodingStandard/ruleset.xml">
<exclude name="SlevomatCodingStandard.Namespaces.FullyQualifiedClassNameAfterKeyword"/>
<exclude name="SlevomatCodingStandard.Namespaces.FullyQualifiedClassNameAfterKeyword"/>
<exclude name="SlevomatCodingStandard.Namespaces.FullyQualifiedExceptions"/>
<exclude name="SlevomatCodingStandard.Namespaces.ReferenceUsedNamesOnly"/>
<exclude name="SlevomatCodingStandard.Namespaces.UseOnlyWhitelistedNamespaces"/>
<exclude name="SlevomatCodingStandard.Types.EmptyLinesAroundTypeBraces"/>
<exclude name="SlevomatCodingStandard.Files.TypeNameMatchesFileName"/>
<exclude name="SlevomatCodingStandard.Arrays.TrailingArrayComma"/>
<exclude name="SlevomatCodingStandard.Namespaces.AlphabeticallySortedUses"/>
<exclude name="SlevomatCodingStandard.TypeHints.LongTypeHints"/>
<exclude name="SlevomatCodingStandard.Classes.ClassConstantVisibility"/>
<exclude name="SlevomatCodingStandard.Namespaces.FullyQualifiedClassNameInAnnotation"/>
</rule>
<rule ref="Squiz.Strings.ConcatenationSpacing">
<properties>
<property name="spacing" value="1"/>
<property name="ignoreNewlines" value="true" />
</properties>
</rule>
<rule ref="Generic.Files.LineLength">
<properties>
<property name="lineLimit" value="180"/>
</properties>
</rule>
<rule ref="Squiz.WhiteSpace.SuperfluousWhitespace">
<properties>
<property name="ignoreBlankLines" value="false"/>
</properties>
</rule>
<rule ref="Squiz.WhiteSpace.SuperfluousWhitespace.EmptyLines">
<severity>5</severity>
</rule>
<rule ref="SlevomatCodingStandard.Namespaces.UnusedUses">
<properties>
<property name="searchAnnotations " value="true"/>
</properties>
</rule>
<rule ref="SlevomatCodingStandard.TypeHints.TypeHintDeclaration">
<properties>
<property name="usefulAnnotations" type="array" value="@Route,@Template,@Cache,@Method,@ParamConverter,@Security"/>
</properties>
</rule>
<rule ref="SlevomatCodingStandard.Classes.UnusedPrivateElements">
<properties>
<property name="alwaysUsedPropertiesAnnotations" type="array" value="@ORM\Column"/>
</properties>
</rule>
<rule ref="SlevomatCodingStandard.TypeHints.DeclareStrictTypes">
<properties>
<property name="newlinesCountBetweenOpenTagAndDeclare" value="2"/>
<property name="spacesCountAroundEqualsSign" value="0"/>
</properties>
</rule>
<!--
<rule ref="SlevomatCodingStandard.Files.TypeNameMatchesFileName">
<properties>
<property name="rootNamespaces" type="array" value="src/=>App,tests=>Tests"/>
</properties>
</rule>
-->
<!-- additional settings -->
</ruleset>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment