basic command: docker run --rm -v /$(PWD):/workspace brunoconte3/phpcs .
specifying the PSR and ignore folder: docker run --rm -v /$(PWD):/workspace brunoconte3/phpcs . --standard=PSR12 --ignore=/View//
specifying your ruleset.xml docker run --rm -v "C:/Docker/ext/phpcs/src/Standards/PSR12/ruleset.xml:/root/.composer/vendor/squizlabs/php_codesniffer/src/Standards/PSR12/ruleset.xml" -v /$(PWD):/workspace brunoconte3/phpcs . --standard=PSR12 --ignore=/View//
docker-compose.yml
phpcs:
image: brunoconte3/phpcs
container_name: phpcs
volumes:
- "c:/Docker/ext/phpcs/src/Standards/PSR12/ruleset.xml:/root/.composer/vendor/squizlabs/php_codesniffer/src/Standards/PSR12/ruleset.xml"
There were cases that in addition to the alias, it needs to be in docker-composer.yml also to work
Content type
Image
Digest
sha256:d568caef8…
Size
298.2 MB
Last updated
4 months ago
docker pull brunoconte3/phpcs