定制 mapado/php-cs-fixer-config 二次开发

按需修改功能、优化性能、对接业务系统,提供一站式技术支持

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

mapado/php-cs-fixer-config

最新稳定版本:v5.0.0

Composer 安装命令:

composer require mapado/php-cs-fixer-config

包简介

Mapado PHP CS Fixer configuration

README 文档

README

PHP CS Fixer config for Mapado.

Installation

$ composer require --dev mapado/php-cs-fixer-config

Usage

Configuration

Create a configuration file .php_cs in the root of your project:

<?php

require(__DIR__ .'/vendor/autoload.php');

$config = new \Mapado\CS\Config();

$config->getFinder()
    ->in([
        __DIR__.'/src',
    ])
    // if you want to exclude Tests directory
    // ->exclude([ 'Tests' ])
;

return $config;

Run

bin/php-cs-fixer fix --config=.php_cs

In project

You might want to use lint-staged, php-git-hooks or composer-git-hooks to run this command automatically on git files, or autofix on save in your IDE.

Git

Add .php_cs.cache (this is the cache file created by php-cs-fixer) to .gitignore:

License

This project is licensed under the MIT license.

统计信息

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

GitHub 信息

  • Stars: 0
  • Watchers: 7
  • Forks: 0
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2017-06-29