-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
2 changed files
with
57 additions
and
14 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,25 +1,68 @@ | ||
<?xml version="1.0"?> | ||
<ruleset name="MyProject Rules" | ||
<ruleset name="OpenCatalogi Nextcloud Rules" | ||
xmlns="http://pmd.sourceforge.net/ruleset/2.0.0" | ||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" | ||
xsi:schemaLocation="http://pmd.sourceforge.net/ruleset/2.0.0 | ||
http://pmd.sourceforge.net/ruleset_xml_schema.xsd" | ||
xsi:noNamespaceSchemaLocation="http://pmd.sourceforge.net/ruleset_xml_schema.xsd"> | ||
http://pmd.sourceforge.net/ruleset_xml_schema.xsd"> | ||
|
||
<description> | ||
This is a custom ruleset for OpenCatalogi Nextcloud. | ||
</description> | ||
|
||
<!-- Add the rules you want to use here --> | ||
<rule ref="rulesets/design.xml"/> | ||
<rule ref="rulesets/unusedcode.xml"/> | ||
<rule ref="rulesets/naming.xml"/> | ||
<rule ref="rulesets/cleancode.xml"/> | ||
<rule ref="rulesets/codesize.xml"/> | ||
<rule ref="rulesets/controversial.xml"/> | ||
<rule ref="rulesets/codesize.xml/ExcessiveClassLength"/> | ||
<!-- Clean Code Rules --> | ||
<rule ref="rulesets/cleancode.xml/BooleanArgumentFlag"/> | ||
<rule ref="rulesets/cleancode.xml/ElseExpression"/> | ||
<rule ref="rulesets/cleancode.xml/StaticAccess"/> | ||
<rule ref="rulesets/cleancode.xml/IfStatementAssignment"/> | ||
<rule ref="rulesets/cleancode.xml/DuplicatedArrayKey"/> | ||
<rule ref="rulesets/cleancode.xml/MissingImport"/> | ||
<rule ref="rulesets/cleancode.xml/UndefinedVariable"/> | ||
<rule ref="rulesets/cleancode.xml/ErrorControlOperator"/> | ||
|
||
<!-- Code Size Rules --> | ||
<rule ref="rulesets/codesize.xml/CyclomaticComplexity"/> | ||
<rule ref="rulesets/codesize.xml/NPathComplexity"/> | ||
<rule ref="rulesets/codesize.xml/ExcessiveMethodLength"/> | ||
<rule ref="rulesets/codesize.xml/ExcessiveClassLength"/> | ||
<rule ref="rulesets/codesize.xml/ExcessiveParameterList"/> | ||
<rule ref="rulesets/codesize.xml/ExcessivePublicCount"/> | ||
<rule ref="rulesets/codesize.xml/TooManyFields"/> | ||
<rule ref="rulesets/codesize.xml/TooManyMethods"/> | ||
<rule ref="rulesets/codesize.xml/TooManyPublicMethods"/> | ||
<rule ref="rulesets/codesize.xml/ExcessiveClassComplexity"/> | ||
|
||
<!-- Controversial Rules --> | ||
<rule ref="rulesets/controversial.xml/Superglobals"/> | ||
<rule ref="rulesets/controversial.xml/CamelCaseClassName"/> | ||
<rule ref="rulesets/controversial.xml/CamelCasePropertyName"/> | ||
<rule ref="rulesets/controversial.xml/CamelCaseMethodName"/> | ||
<rule ref="rulesets/controversial.xml/CamelCaseParameterName"/> | ||
<rule ref="rulesets/controversial.xml/CamelCaseVariableName"/> | ||
|
||
<!-- Design Rules --> | ||
<rule ref="rulesets/design.xml/ExitExpression"/> | ||
<rule ref="rulesets/design.xml/EvalExpression"/> | ||
<rule ref="rulesets/design.xml/GotoStatement"/> | ||
<rule ref="rulesets/design.xml/NumberOfChildren"/> | ||
<rule ref="rulesets/design.xml/DepthOfInheritance"/> | ||
<rule ref="rulesets/design.xml/CouplingBetweenObjects"/> | ||
<rule ref="rulesets/design.xml/DevelopmentCodeFragment"/> | ||
<rule ref="rulesets/design.xml/EmptyCatchBlock"/> | ||
<rule ref="rulesets/design.xml/CountInLoopExpression"/> | ||
|
||
<!-- Naming Rules --> | ||
<rule ref="rulesets/naming.xml/LongClassName"/> | ||
<rule ref="rulesets/naming.xml/ShortClassName"/> | ||
<rule ref="rulesets/naming.xml/ShortVariable"/> | ||
<rule ref="rulesets/naming.xml/LongVariable"/> | ||
<rule ref="rulesets/naming.xml/ShortMethodName"/> | ||
<rule ref="rulesets/naming.xml/ConstructorWithNameAsEnclosingClass"/> | ||
<rule ref="rulesets/naming.xml/ConstantNamingConventions"/> | ||
<rule ref="rulesets/naming.xml/BooleanGetMethodName"/> | ||
|
||
<!-- Unused Code Rules --> | ||
<rule ref="rulesets/unusedcode.xml/UnusedPrivateField"/> | ||
<rule ref="rulesets/unusedcode.xml/UnusedLocalVariable"/> | ||
<rule ref="rulesets/unusedcode.xml/UnusedPrivateMethod"/> | ||
<rule ref="rulesets/unusedcode.xml/UnusedFormalParameter"/> | ||
</ruleset> |