From d6c699a130908e1c72085fc5dea94e6dee42f689 Mon Sep 17 00:00:00 2001 From: Massimiliano Arione Date: Tue, 2 Jan 2024 14:38:45 +0100 Subject: [PATCH] =?UTF-8?q?=E2=AC=86=EF=B8=8F=20=20drop=20support=20for=20?= =?UTF-8?q?PHP=207?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/build.yaml | 15 ++++++++------- .php_cs => .php-cs-fixer.php | 10 ++++------ composer.json | 10 +++++----- 3 files changed, 17 insertions(+), 18 deletions(-) rename .php_cs => .php-cs-fixer.php (58%) diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 5a8be4f..095b730 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -5,19 +5,20 @@ on: push: ~ jobs: + cs-fixer: + runs-on: ubuntu-22.04 + name: PHP-CS-Fixer + steps: + - name: Checkout + uses: actions/checkout@v3 + - name: Fix CS + uses: docker://oskarstark/php-cs-fixer-ga tests: runs-on: ubuntu-22.04 strategy: matrix: include: - description: 'lowest' - php: '7.2' - composer_option: '--prefer-lowest' - - description: '7.3' - php: '7.3' - - description: '7.4' - php: '7.4' - - description: '8.0' php: '8.0' - description: '8.1' php: '8.1' diff --git a/.php_cs b/.php-cs-fixer.php similarity index 58% rename from .php_cs rename to .php-cs-fixer.php index 51a9f78..c12ae97 100644 --- a/.php_cs +++ b/.php-cs-fixer.php @@ -5,17 +5,15 @@ ->in([__DIR__.'/src', __DIR__.'/tests']) ; -return PhpCsFixer\Config::create() +return (new PhpCsFixer\Config()) ->setRiskyAllowed(true) ->setRules([ '@Symfony' => true, '@Symfony:risky' => true, - '@PHP71Migration:risky' => true, - '@PHPUnit75Migration:risky' => true, - 'array_syntax' => ['syntax' => 'short'], - 'ordered_imports' => true, + '@PHP80Migration:risky' => true, + '@PHPUnit84Migration:risky' => true, 'declare_strict_types' => false, - 'native_function_invocation' => true, + 'native_function_invocation' => ['include' => ['@all']], 'final_class' => true, ]) ->setFinder($finder) diff --git a/composer.json b/composer.json index 3bf3094..0551e88 100644 --- a/composer.json +++ b/composer.json @@ -21,20 +21,20 @@ } ], "require": { - "php": "^7.1 || ^8.0", - "doctrine/orm": "^2.6", + "php": "^8.0", + "doctrine/orm": "^2.7", "pugx/shortid-php": "^1.0" }, "require-dev": { - "dg/bypass-finals": "^1.3", - "phpunit/phpunit": "^8.5 || ^9.5" + "dg/bypass-finals": "^1.5", + "phpunit/phpunit": "^9.6" }, "config": { "bin-dir": "bin" }, "extra": { "branch-alias": { - "dev-master": "1.0-dev" + "dev-master": "1.x-dev" } }, "autoload": {