squizlabs / PHP_CodeSniffer

PHP_CodeSniffer tokenizes PHP files and detects violations of a defined set of coding standards.
BSD 3-Clause "New" or "Revised" License
10.62k stars 1.48k forks source link

Automatically register standard if package type is given #2892

Open mikk150 opened 4 years ago

mikk150 commented 4 years ago

Right now people are using phpcodesniffer-composer-installer to automagically register standards .

Could this be integrated to CodeSniffer? would be really helpful thing to have

jrfnl commented 1 year ago

The installer is based on a directory layout as found for a Composer installation, while PHPCS supports installation via PEAR, as a PHAR file, via Phive, via Composer, as a git clone etc.

While for a Composer install, the location to find standards is relatively predictable - vendor or a custom install directory -, this is not the case when PHPCS is installed via any of the other supported methods.

How do you envision PHPCS could do this ?