0.0
No commit activity in last 3 years
No release in over 3 years
Guard::PHPMD automatically runs PHP Mess Detector when watched files are modified.
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies

Runtime

~> 2.0
 Project Readme

Guard::PHPMD

This guard will run PHP Mess Detector for you automatically when files are modified.

Install

Make sure you have guard and phpmd installed.

Install the gem with:

gem install guard-phpmd

Or add it to your Gemfile:

gem 'guard-phpmd'

And then add a basic setup to your Guardfile:

guard init phpmd

Options

  • :path # default => "."

Set the working directory (useful when using relative paths used in the rules file)

  • :rules # default => "pmd-rules.xml"

Path to the rules file.

  • :executable # default => "phpmd"

Specify the path to the phpmd executable. Useful when installing phpmd with Composer.

Example

guard 'phpmd', :executable => 'path/to/PHPMD', :rules => 'path/to/pmd-rules.xml' do
	watch(%r{.*\.php$})
end