Skip to content

Latest commit

 

History

10 提交

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 
 
 

仓库 files navigation

StreamCommon Team Coding Standard

Latest Stable Version Total Downloads License

Installation

  1. Install the module via composer:
    • Console run:
        composer require --dev streamcommon/coding-standard
    • Or add into your composer.json:
        "require-dev": {
            "streamcommon/coding-standard": "*"
        }
  2. Add composer scripts into your composer.json:
         "scripts": {
             "cs-check": "phpcs",
             "cs-fix": "phpcbf"
         }
  3. Create file phpcs.xml:
        <?xml version="1.0"?>
            <ruleset name="StreamCommon Team Coding Standard">
            <rule ref="./vendor/streamcommon/coding-standard/ruleset.xml"/>
            <file>bin</file>
            <file>config</file>
            <file>lib</file>
            <file>src</file>
            <file>test</file>
        </ruleset>

Usage

Run: composer cs-check OR composer cs-fix

Customize

See https://github.com/squizlabs/PHP_CodeSniffer/wiki/Annotated-ruleset.xml

关于

StreamCommon Team Coding Standard

Topics

Resources

Stars

0 stars

关注者

1 watching

复刻s

发布

Used by

贡献者