Last active
September 12, 2024 15:51
-
-
Save DominicWatts/8f19d5de6f7e82257df0e1a612eaed84 to your computer and use it in GitHub Desktop.
Magento 2 : PHPCS docker #magento2
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
docker run --rm -v $PWD:/code domw/phpcs phpcs --colors --standard=Magento2 --report=full,summary --extensions=php,phtml ./ | |
# hide warnings | |
https://github.com/squizlabs/PHP_CodeSniffer/wiki/Configuration-Options#hiding-warnings-by-default | |
phpcs --error-severity=1 --warning-severity=0 /path/to/code | |
--config-set warning_severity 0 | |
# standard syntax | |
phpcs --colors --standard=Magento2 --report=full,summary --extensions=php,phtml ./ | |
phpcbf --colors --standard=Magento2 --report=full,summary --extensions=php,phtml ./ |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment