bytic / phpqaconfig
PHP QA 工具配置文件的元包
1.0.13
2024-04-02 19:35 UTC
Requires
- php: ^7.4 || ^8
- dealerdirect/phpcodesniffer-composer-installer: ^0.7.0||^1.0.0
- phpcsstandards/phpcsextra: ^1.0
- phpcsstandards/phpcsutils: ^1.0
- slevomat/coding-standard: ^7.0||^8.0
- squizlabs/php_codesniffer: ^3.5
Requires (Dev)
- friendsofphp/php-cs-fixer: ^2.8 || ^3.0
README
PHP 代码检查器
配置文件: bytic.phpcs.xml
使用方法
-
将 bytic/qaconfig 仓库链接为 composer 依赖项
$ composer require bytic/qaconfig:^1.0
-
扩展提供的配置以适应您的项目。
<?xml version="1.0" encoding="UTF-8"?> <ruleset name="DEMO-PHP project code style checker config"> <rule ref="./vendor/bytic/qaconfig/bytic.phpcs.xml"> <exclude name="PSR2.Classes.PropertyDeclaration.Underscore"/> </rule> <rule ref="PSR1.Classes.ClassDeclaration"> <exclude-pattern>*/_stubs.php</exclude-pattern> </rule> <rule ref="Generic.CodeAnalysis.UnconditionalIfStatement.Found"> <exclude-pattern>*/_stubs.php</exclude-pattern> </rule> </ruleset>