nepada/coding-standard

Nepada 编码规范。

安装数: 256,658

依赖: 24

建议者: 0

安全性: 0

星标: 2

关注者: 3

分支: 0

公开问题: 0

类型:phpcodesniffer-standard

v7.14.0 2023-12-16 20:25 UTC

README

Build Status Downloads this Month Latest stable

基于 Consistence - Coding StandardSlevomat - Coding Standard

安装

通过 Composer

$ composer require nepada/coding-standard

使用

您可以直接使用规则集,也可以根据需要自定义

<?xml version="1.0"?>
<ruleset>
    <config name="installed_paths" value="../../nepada/coding-standard/src"/><!-- relative path from PHPCS source location -->

    <arg value="ps"/><!-- show progress of the run, show sniff names -->
    <arg name="cache" value=".phpcs-cache"/>

    <file>src</file>
    <file>tests</file>

    <rule ref="Nepada">
    </rule>
</ruleset>

要检查您的代码库中的违规行为,请从命令行运行 PHP CodeSniffer

vendor/bin/phpcs