2.0.1 • Published 8 years ago

gulp-phpmd v2.0.1

Weekly downloads
12
License
MIT
Repository
github
Last release
8 years ago

gulp-phpmd NPM version

A gulp plugin for running PHP Mess Detector.

Derivative work of Dmitriy S. Simushev's gulp-phpcs ##Requirements

##Installation

npm install gulp-phpmd --save-dev

Usage

var gulp = require('gulp');
var phpmd = require('gulp-phpmd');

gulp.task('default', function () {
    return gulp.src(['src/**/*.php', '!src/vendor/**/*.*'])
        // Validate code using PHP Mess Detector
        .pipe(phpmd({
            bin: 'src/vendor/bin/phpmd',
            format: 'text',
            ruleset: 'unusedcode',
        }))
        .on('error', console.error)
});

API

phpmd(options)

options.bin

Type: String

Default: 'phpmd'

PHP Mess Detector executable.

options.ruleset

Type: String

The format of the report, for multiple formats just use a comma separated string.

options.ruleset

Type: String

The ruleset to check against

options.minimumpriority

Type: String

pass --mininumpriority to phpmd

options.strict

Type: String

pass --strict to phpmd

License

MIT © Higashi Ryohei

2.0.1

8 years ago

2.0.0

8 years ago

0.0.1

8 years ago

0.1.0

8 years ago

1.0.0

8 years ago