2017 © Pedro Peláez
 

library phpmd-rulesets

Exetnded mess detection rules from phpmd for BTC applications.

image

btc/phpmd-rulesets

Exetnded mess detection rules from phpmd for BTC applications.

  • Friday, January 20, 2017
  • by damienlagae
  • Repository
  • 5 Watchers
  • 0 Stars
  • 659 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 2 Versions
  • 16 % Grown

The README.md

DEPRECATED

This is no longer supported, (*1)

BTC\PHPMD-Rulesets

Features

Extends phpmd with rules for BTC applications. Also add extra rules from clean code., (*2)

  • Clean Code
    • ClassNameSingleResponsibility
    • MethodOneTryCatch
    • SuperfluousComment
    • InlineIf
    • MeaninglessMethodName
    • TraitPublicMethod
    • SwitchStatement
  • Symfony
    • ControllerMethodName
    • EntitySimpleGetterSetter
    • EntityConstants
    • ConstructorNewOperator

Installation

Open a command console, enter your project directory and execute the following command to download the latest stable version:, (*3)

composer require --dev btc/phpmd-rulesets

OR, (*4)

Composer is used for installation. Add the following lines to your composer.jon file:, (*5)

"require-dev": {
  "btc/phpmd-rulesets": "^1.0"
}

Usage

Use grumphp and configure phpmd task with the following lines in your grumphp.yml, (*6)

phpmd:
    exclude: ['vendor']
    ruleset: ['/vendor/btc/phpmd-rulesets/Rulesets/symfony.xml', '/vendor/btc/phpmd-rulesets/Rulesets/cleancode.xml']
    triggered_by: [php]

The Versions