php-censor/docs/en/plugins/php_cs_fixes.md

31 lines
908 B
Markdown
Raw Normal View History

2016-07-19 11:12:28 +02:00
Plugin PHP Coding Standards Fixer
2017-01-04 13:22:20 +01:00
=================================
2016-07-19 11:12:28 +02:00
2016-07-17 16:20:35 +02:00
Runs PHP Coding Standards Fixer against your build.
2016-07-19 11:12:28 +02:00
Configuration
2017-01-04 13:22:20 +01:00
-------------
2016-07-19 11:12:28 +02:00
2016-07-17 16:20:35 +02:00
### Options
2016-07-19 11:12:28 +02:00
2016-07-17 16:20:35 +02:00
* **verbose** [bool, optional] - Whether to run in verbose mode (default: false)
* **diff** [bool, optional] - Whether to run with the `--diff` flag enabled (default: false)
* **level** [string, optional] - `psr0`, `psr1`, `psr2`, or `symphony` (default: all)
* **workingdir** [string, optional] - The directory in which PHP CS Fixer should work (default: build root)
2016-07-19 11:12:28 +02:00
### Examples
2016-07-17 16:20:35 +02:00
```yml
test:
php_cs_fixer:
verbose: true
diff: true
level: "psr2"
workingdir: "my/dir/path"
```
2016-07-19 11:12:28 +02:00
Warning
2017-01-04 13:22:20 +01:00
-------
2016-07-19 11:12:28 +02:00
2016-07-17 16:20:35 +02:00
There is currently a bug with this plugin that will cause an error if you leave the level to default to `all`. That level does not exist and will cause the build to fail. Instead specify the level explicitly until this is fixed.