Moxio / php-codesniffer-sniffs

Custom sniffs for PHP_CodeSniffer
MIT License
17 stars 10 forks source link

Allow slevomat/coding-standard ^7.0 #10

Closed Jeroeny closed 3 years ago

Jeroeny commented 3 years ago

This PR allows slevomat/coding-standard ^7.0 to be installed.

You also might want to .gitignore the composer.lock file, as it has no effect in libraries.

aboks commented 3 years ago

I'm a bit reluctant to merge this as-is. We rely on the slevomat coding standard for their helpers, which according to the changelog are considered internal as of version 7. This means that that they can break BC for the helpers (or just remove them entirely) within the 7.x-range, which would break our sniffs.

In the long run, it seems like a bad idea to keep relying on the slevomat helpers, as their API is no longer guaranteed. I will see if there is something available to replace them. In the short run, we could allow versions 7.0.0-7.0.4, which still seem compatible. Would that be sufficient for your use case?

Jeroeny commented 3 years ago

Understandable, yes allowing just those versions would also help.

aboks commented 3 years ago

Version 2.5.1 can be used with slevomat/coding-standard 7.0.0-7.0.4.