Install PHP Mess Detector (phpmd)

What is PHP Mess Detector? Given its homepage, it aims to detect:

  • Possible bugs
  • Suboptimal code
  • Overcomplicated expressions
  • Unused parameters, methods, properties

In short: it helps by pointing you on the mess inside your PHP scripts!

Listing available packages:

$ pear channel-discover
$ pear channel-discover
 Adding Channel "" succeeded
 Discovery of channel "" succeeded
 Adding Channel "" succeeded

Now, check which packages (and versions) are available on the server.

$ pear remote-list -c phpmd
Channel phpmd Available packages: 
Package Version PHP_PMD 1.4.1

Install the latest version

$ sudo pear install --alldeps phpmd/PHP_PMD

Now what?


One thought on “Install PHP Mess Detector (phpmd)

Leave a Reply

Your email address will not be published. Required fields are marked *