shipmonk / coding-standard
PHP Coding Standard used in ShipMonk
Installs: 363
Dependents: 10
Suggesters: 0
Security: 0
Stars: 0
Watchers: 0
Forks: 0
Open Issues: 0
Type:phpcodesniffer-standard
Requires
- php: ^7.4 || ^8.0
- slevomat/coding-standard: ^8.19.1
Requires (Dev)
- ext-simplexml: *
- editorconfig-checker/editorconfig-checker: ^10.6
- ergebnis/composer-normalize: ^2.45
- phpstan/phpstan: ^2.1
- phpstan/phpstan-phpunit: ^2.0
- phpstan/phpstan-strict-rules: ^2.0
- phpunit/phpunit: ^9.6
- shipmonk/composer-dependency-analyser: ^1.8
- shipmonk/dead-code-detector: ^0.12
- shipmonk/name-collision-detector: ^2.1
- shipmonk/phpstan-rules: ^4.1
This package is auto-updated.
Last update: 2025-06-16 11:44:36 UTC
README
PHP Coding Standard used in ShipMonk
Note
This coding standard is primarily intended for use by ShipMonk packages. For other applications or packages, consider using slevomat/coding-standard directly instead.
Installation
composer require --dev shipmonk/coding-standard
Configuration
Create phpcs.xml.dist
in your project root:
<?xml version="1.0"?> <ruleset xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="vendor/squizlabs/php_codesniffer/phpcs.xsd" > <arg name="basepath" value="."/> <arg name="cache" value="var/phpcs.cache"/> <file>src/</file> <file>tests/</file> <config name="installed_paths" value="vendor/slevomat/coding-standard,vendor/shipmonk/coding-standard"/> <rule ref="ShipMonkCodingStandard"/> </ruleset>
Usage
Check your code:
vendor/bin/phpcs
Fix auto-fixable issues:
vendor/bin/phpcbf