.php_cs 976 B

12345678910111213141516171819202122232425262728293031323334353637383940
  1. <?php
  2. /*
  3. * DO NOT EDIT THIS FILE!
  4. *
  5. * It's auto-generated by sonata-project/dev-kit package.
  6. *
  7. * Package `sllh/php-cs-fixer-styleci-bridge` is required to get it working.
  8. */
  9. require_once __DIR__.'/vendor/sllh/php-cs-fixer-styleci-bridge/autoload.php';
  10. use SLLH\StyleCIBridge\ConfigBridge;
  11. $header = <<<EOF
  12. This file is part of the Sonata Project package.
  13. (c) Thomas Rabaix <thomas.rabaix@sonata-project.org>
  14. For the full copyright and license information, please view the LICENSE
  15. file that was distributed with this source code.
  16. EOF;
  17. // PHP-CS-Fixer 1.x
  18. if (class_exists('Symfony\CS\Fixer\Contrib\HeaderCommentFixer')) {
  19. \Symfony\CS\Fixer\Contrib\HeaderCommentFixer::setHeader($header);
  20. }
  21. $config = ConfigBridge::create()
  22. ->setUsingCache(true)
  23. ;
  24. // PHP-CS-Fixer 2.x
  25. if (method_exists($config, 'setRules')) {
  26. $config->setRules(array_merge($config->getRules(), array(
  27. 'header_comment' => array('header' => $header)
  28. )));
  29. }
  30. return $config;