Skip to content

Commit

Permalink
Update PHP-CS-Fixer to v3.11 (#22)
Browse files Browse the repository at this point in the history
  • Loading branch information
mpdude authored Oct 25, 2022
1 parent 7a6e657 commit 137f4c6
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 5 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/fix-cs-php.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ jobs:
ref: ${{ github.head_ref }}

- name: Run PHP-CS-Fixer
uses: docker://oskarstark/php-cs-fixer-ga:2.16.7
uses: docker://oskarstark/php-cs-fixer-ga:3.11.0

- name: Create PR for CS fixups
uses: peter-evans/create-pull-request@c7f493a8000b8aeb17a1332e326ba76b57cb83eb
Expand Down
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@ var/
vendor/
composer.lock
.phpunit.*
.php_cs.cache
.php-cs-fixer.cache
10 changes: 7 additions & 3 deletions .php_cs.dist → .php-cs-fixer.dist.php
Original file line number Diff line number Diff line change
@@ -1,14 +1,18 @@
<?php

return PhpCsFixer\Config::create()
return (new PhpCsFixer\Config())
->setRules([
'@Symfony' => true,
'@Symfony:risky' => true,
'array_syntax' => array('syntax' => 'short'),
'array_syntax' => ['syntax' => 'short'],
'no_unreachable_default_argument_value' => false,
'braces' => array('allow_single_line_closure' => true),
'braces' => ['allow_single_line_closure' => true],
'heredoc_to_nowdoc' => false,
'phpdoc_annotation_without_dot' => false,
'php_unit_test_annotation' => false,
'php_unit_method_casing' => false,
'global_namespace_import' => ['import_classes' => true, 'import_constants' => false, 'import_functions' => false],
'psr_autoloading' => false,
])
->setRiskyAllowed(true)
->setFinder(
Expand Down

0 comments on commit 137f4c6

Please sign in to comment.