📜  php 混乱检测器 - PHP 代码示例

📅  最后修改于: 2022-03-11 14:53:40.785000             🧑  作者: Mango

代码示例1
# install PHPMD - PHP Mess Detector
composer require --dev phpmd/phpmd
  
# generate phpmd.html with standard ruleset
vendor/bin/phpmd app html cleancode,codesize,controversial,design,naming,unusedcode > phpmd.html
  
# use this phpmd-ruleset.xml https://gist.github.com/slayerfat/2b3cc4faf94d2863b505 (for laravel) to avoid facades problem
vendor/bin/phpmd app html ./phpmd-ruleset.xml > phpmd.html
  
# Removal
composer remove --dev phpmd/phpmd
rm phpmd-ruleset.xml
rm phpmd.html