<?php

$header = <<<EOF
(c) Rob Bast <rob.bast@gmail.com>

For the full copyright and license information, please view
the LICENSE file that was distributed with this source code.
EOF;

$finder = new PhpCsFixer\Finder();
$config = new PhpCsFixer\Config('ISO4217', 'ISO4217 style guide');

$finder
    ->in(__DIR__)
;

/* Based on dev-master|^2.0 of php-cs-fixer */
$config
    ->setRules([
        // default
        '@PSR2' => true,
        '@Symfony' => true,
        // additionally
        'concat_with_spaces' => true,
        'concat_without_spaces' => false,
        'header_comment' => ['header' => $header],
        'no_unused_imports' => false,
        'no_useless_else' => true,
        'no_useless_return' => true,
        'ordered_imports' => true,
        'phpdoc_align' => false,
        'phpdoc_order' => true,
        'phpdoc_params' => false,
        'phpdoc_summary' => false,
        'short_array_syntax' => true,
        'simplified_null_return' => false,
    ])
    ->setFinder($finder)
;

return $config;
