Open robfrawley opened 7 years ago
This incompatibility occurred somewhere between the release of v2.0.0alpha and v2.0.0beta of php-cs-fixer.
Diff between d0d76b4 and 962b2c5 contains the affected changed...somewhere.
@Soullivaneuh The PHP-CS-Fixer 2.0 is stable now and we are unable to upgrade.
This is really my fault because there are 54 fixer alises and 26 virtual fixers in StyleCI, so it's actually impossible to map to php-cs-fixer with ease.
The mapping class StyleCI has is 278 lines long, and that deals with the virtual fixers only. The other config class it has to deal with presets, aliases, and conflicts is 842 lines long. These remain closed source though I'm afraid, because they're of high value.
I think it would be a good idea to expose a styleci.yml to php-cs-fixer config config converter on the API. Well, expose a partial version, that is, that takes the risky setting along with the preset and enabled/disabled lists, then generates a list of php-cs-fixers and their config, in the same format as for that tool.
Ok, I've done that then, similar to the "validate" endpoint, just pass the config file as the "config" parameter. For example: https://api.styleci.io/rules?config=preset:%20psr2. Unlike the validate endpoint, empty config is supported. The design decision with not permitting this on the other endpoint was because it was targeted at validation, so we wanted to be sure people weren't accidently passing nothing. On this endpoint, nothing is treated like the empty config file, you get all the rules generated from the recommended preset with risky enabled.
Replaced by https://github.com/StyleCI/CLI.
After my most recent
composer update
I am getting a fatal error when runningbin/php-cs-fixer
with the bridge.With the following dependencies:
And the following
.php_cs.dist
And the following
.styleci.yml