Skip to content

Instantly share code, notes, and snippets.

@fastmover
Created December 31, 2016 19:55
Show Gist options
  • Select an option

  • Save fastmover/691b6a079164af75178d47b2bec8b81d to your computer and use it in GitHub Desktop.

Select an option

Save fastmover/691b6a079164af75178d47b2bec8b81d to your computer and use it in GitHub Desktop.
PHP CS Fixer 2.x project file
<?php
if (class_exists('PhpCsFixer\Finder')) {
$finder = PhpCsFixer\Finder::create()
->in(__DIR__)
;
return PhpCsFixer\Config::create()
->setRules(array(
'@PSR2' => true,
'@Symfony' => true,
'array_syntax' => true,
'linebreak_after_opening_tag' => true,
'not_operator_with_successor_space' => true,
'ordered_imports' => true,
'ordered_class_elements' => true,
'phpdoc_add_missing_param_annotation' => true,
'phpdoc_order' => true,
))
->setFinder($finder)
;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment