承接 sun-asterisk/coding-standard 相关项目开发

从需求分析到上线部署,全程专人跟进,保证项目质量与交付效率

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

sun-asterisk/coding-standard

最新稳定版本:v0.2.5

Composer 安装命令:

composer require sun-asterisk/coding-standard

包简介

Sun* R&D PHP coding standard

README 文档

README

Latest Stable Version

Sun* coding standard for PHP_CodeSniffer.

Installation

Using composer

composer require --dev sun-asterisk/coding-standard

Usage

Add the SunAsterisk standard to your project's phpcs.xml:

<?xml version="1.0" encoding="UTF-8"?>
<ruleset name="YourProject" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
    <rule ref="SunAsterisk"/>
</ruleset>

Or use it on the command line

vendor/bin/phpcs --standard=SunAsterisk <file or directory to check>

Laravel

The SunAsteriskLaravel standard is extended for Laravel projects. You can use it as below:

<?xml version="1.0" encoding="UTF-8"?>
<ruleset name="YourProject" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
    <file>app</file>
    <file>config</file>
    <file>database</file>
    <file>resources</file>
    <file>routes</file>
    <file>tests</file>

    <exclude-pattern>vendor/</exclude-pattern>

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

Refer to the phpcs documents for more detailed usage. Also refer to slevomat/coding-standard for details on some sniffs.

统计信息

  • 总下载量: 41.58k
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 4
  • 点击次数: 1
  • 依赖项目数: 2
  • 推荐数: 0

GitHub 信息

  • Stars: 4
  • Watchers: 0
  • Forks: 3
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2020-02-10