124 Star 554 Fork 132

GVPswoft / swoft

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
.php_cs 1.19 KB
一键复制 编辑 原始数据 按行查看 历史
inhere 提交于 2020-09-13 22:57 . update some examples
<?php
$header = <<<'EOF'
This file is part of Swoft.
@link https://swoft.org
@document https://swoft.org/docs
@contact group@swoft.org
@license https://github.com/swoft-cloud/swoft/blob/master/LICENSE
EOF;
return PhpCsFixer\Config::create()
->setRiskyAllowed(true)
->setRules([
'@PSR2' => true,
'array_syntax' => [
'syntax' => 'short'
],
'class_attributes_separation' => true,
'declare_strict_types' => true,
'encoding' => true, // MUST use only UTF-8 without BOM
'global_namespace_import' => [
'import_constants' => true,
'import_functions' => true,
],
'header_comment' => [
'comment_type' => 'PHPDoc',
'header' => $header,
'separate' => 'bottom'
],
'no_unused_imports' => true,
'single_quote' => true,
'standardize_not_equals' => true,
])
->setFinder(
PhpCsFixer\Finder::create()
->exclude('public')
->exclude('resource')
->exclude('config')
->exclude('runtime')
->exclude('vendor')
->in(__DIR__)
)
->setUsingCache(false);
PHP
1
https://gitee.com/swoft/swoft.git
git@gitee.com:swoft/swoft.git
swoft
swoft
swoft
master

搜索帮助