forked from loafle/openapi-generator-original
[PHP] Upgrade php-cs-fixer to 2.12, enables PHP >= 7.2 support (#769)
* upgrade php-cs-fixer to 2.12 * ran petstore-security-test for php * updating openapi3 php petstore example
This commit is contained in:
committed by
Akihito Nakano
parent
b9e9f54dab
commit
a8cbae4dc8
@@ -1,18 +1,23 @@
|
||||
<?php
|
||||
|
||||
return Symfony\CS\Config::create()
|
||||
->level(Symfony\CS\FixerInterface::PSR2_LEVEL)
|
||||
return PhpCsFixer\Config::create()
|
||||
->setUsingCache(true)
|
||||
->fixers(
|
||||
[
|
||||
'ordered_use',
|
||||
'phpdoc_order',
|
||||
'short_array_syntax',
|
||||
'strict',
|
||||
'strict_param'
|
||||
]
|
||||
)
|
||||
->finder(
|
||||
Symfony\CS\Finder\DefaultFinder::create()
|
||||
->in(__DIR__)
|
||||
->setRules([
|
||||
'@PSR2' => true,
|
||||
'ordered_imports' => true,
|
||||
'phpdoc_order' => true,
|
||||
'array_syntax' => [ 'syntax' => 'short' ],
|
||||
'strict_comparison' => true,
|
||||
'strict_param' => true,
|
||||
'no_trailing_whitespace' => false,
|
||||
'no_trailing_whitespace_in_comment' => false,
|
||||
'braces' => false,
|
||||
'single_blank_line_at_eof' => false,
|
||||
'blank_line_after_namespace' => false,
|
||||
])
|
||||
->setFinder(
|
||||
PhpCsFixer\Finder::create()
|
||||
->exclude('test')
|
||||
->exclude('tests')
|
||||
->in(__DIR__)
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user