Details
Description
The problem comes from the way that the PHPCS uses ruleset files.
For instance, the following ruleset file does not work:
<ruleset name="PHP_CodeSniffer rules"> <rule ref="Generic.Files.LineEndings.InvalidEOLChar"> <severity>6</severity> <properties> <property name="eolChar" value="FOO" /> </properties> </rule> </ruleset>
The hack to make it work is to change the generated file into the following (thanks Gabriele Santini for the hint):
<ruleset name="PHP_CodeSniffer rules"> <rule ref="Generic.Files.LineEndings.InvalidEOLChar"> <severity>6</severity> </rule> <rule ref="Generic.Files.LineEndings"> <properties> <property name="eolChar" value="FOO" /> </properties> </rule> </ruleset>
This works, even though this may not be the best option (in the future, we need to see with PHPCS team if there's a way to improve this).