]> BookStack Code Mirror - bookstack/blobdiff - phpcs.xml
Drawings: Added class to extract drawio data from png files
[bookstack] / phpcs.xml
index 009791fc9d4cb33ddc88001dec5fef60172e7dc1..8d4c6b70208d84bef196acc7803533c7efc49269 100644 (file)
--- a/phpcs.xml
+++ b/phpcs.xml
@@ -1,8 +1,35 @@
 <?xml version="1.0"?>
-<ruleset name="PHP_CodeSniffer">
-    <description>The coding standard for BookStack.</description>
+<ruleset xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" name="PHP_CodeSniffer" xsi:noNamespaceSchemaLocation="phpcs.xsd">
+    <description>The coding standard for BookStack</description>
+
     <file>app</file>
-    <exclude-pattern>*/migrations/*</exclude-pattern>
+    <file>bootstrap/app.php</file>
+    <file>database</file>
+    <file>public/index.php</file>
+    <file>routes</file>
+    <file>tests</file>
+
+    <arg name="basepath" value="."/>
+    <arg name="colors"/>
+    <arg name="parallel" value="75"/>
     <arg value="np"/>
-    <rule ref="PSR2"/>
-</ruleset>
\ No newline at end of file
+
+    <rule  ref="PSR12"/>
+
+    <rule ref="PSR1.Methods.CamelCapsMethodName">
+        <exclude-pattern>./tests/*</exclude-pattern>
+    </rule>
+
+    <rule ref="PSR1.Classes.ClassDeclaration.MultipleClasses">
+        <exclude-pattern>./tests/*</exclude-pattern>
+    </rule>
+
+    <rule ref="PSR1.Classes.ClassDeclaration.MissingNamespace">
+        <exclude-pattern>./database/*</exclude-pattern>
+    </rule>
+
+    <rule ref="PSR12.Files.FileHeader.IncorrectOrder">
+        <exclude-pattern>./app/Config/*</exclude-pattern>
+    </rule>
+
+</ruleset>