From e5a542e780864e7a6600972dcae5c25cca88e646 Mon Sep 17 00:00:00 2001 From: Vladimir Jimenez Date: Wed, 31 May 2023 18:30:26 -0700 Subject: [PATCH] Fix GitHub Actions workflows --- .github/workflows/ci.yml | 16 +++++++++------- .github/workflows/linting.yml | 20 ++++++++++---------- composer.json | 8 ++++---- composer.lock | 2 +- 4 files changed, 24 insertions(+), 22 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 1ea4fc1..09fe9e2 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -25,7 +25,7 @@ jobs: steps: - name: Checkout - uses: actions/checkout@v2 + uses: actions/checkout@v3 - name: Set up PHP ${{ matrix.php-versions }} uses: shivammathur/setup-php@v2 @@ -45,10 +45,10 @@ jobs: - name: Get Composer Cache Directory id: composer-cache - run: echo "::set-output name=dir::$(composer config cache-files-dir)" + run: echo "dir=$(composer config cache-files-dir)" >> $GITHUB_OUTPUT - name: Cache dependencies - uses: actions/cache@v2 + uses: actions/cache@v3 with: path: ${{ steps.composer-cache.outputs.dir }} key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.lock') }} @@ -58,11 +58,13 @@ jobs: run: | # Don't use our lock file for unit tests rm composer.lock - - # We do not use it in unit tests + + # Remove PHP 8.1 requirement + sed -i '/"php": ">=8\.1",/d' composer.json + + # Remove dependencies we don't need for unit tests that break platform requirements composer remove --dev \ - friendsofphp/php-cs-fixer \ - kubawerlos/php-cs-fixer-custom-fixers + bamarni/composer-bin-plugin composer install diff --git a/.github/workflows/linting.yml b/.github/workflows/linting.yml index cc33017..e77e1a1 100644 --- a/.github/workflows/linting.yml +++ b/.github/workflows/linting.yml @@ -10,20 +10,20 @@ jobs: runs-on: ubuntu-latest steps: - name: Checkout - uses: actions/checkout@v2 + uses: actions/checkout@v3 - - name: Set up PHP 8.0 + - name: Set up PHP 8.2 uses: shivammathur/setup-php@v2 with: - php-version: '8.0' + php-version: '8.2' extensions: mbstring - name: Get Composer Cache Directory id: composer-cache - run: echo "::set-output name=dir::$(composer config cache-files-dir)" + run: echo "dir=$(composer config cache-files-dir)" >> $GITHUB_OUTPUT - name: Cache dependencies - uses: actions/cache@v2 + uses: actions/cache@v3 with: path: ${{ steps.composer-cache.outputs.dir }} key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.lock') }} @@ -43,20 +43,20 @@ jobs: runs-on: ubuntu-latest steps: - name: Checkout - uses: actions/checkout@v2 + uses: actions/checkout@v3 - - name: Set up PHP 8.0 + - name: Set up PHP 8.2 uses: shivammathur/setup-php@v2 with: - php-version: '8.0' + php-version: '8.2' extensions: mbstring - name: Get Composer Cache Directory id: composer-cache - run: echo "::set-output name=dir::$(composer config cache-files-dir)" + run: echo "dir=$(composer config cache-files-dir)" >> $GITHUB_OUTPUT - name: Cache dependencies - uses: actions/cache@v2 + uses: actions/cache@v3 with: path: ${{ steps.composer-cache.outputs.dir }} key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.lock') }} diff --git a/composer.json b/composer.json index c90464e..cb34559 100644 --- a/composer.json +++ b/composer.json @@ -18,11 +18,11 @@ "php": ">=8.1", "ext-json": "*", "bamarni/composer-bin-plugin": "^1.8", - "doctrine/instantiator": "^1.4", + "doctrine/instantiator": "^1.0||^1.1||^1.4", "erusev/parsedown": "^1.7", - "nikic/php-parser": "^4.13", - "phpdocumentor/reflection-docblock": "^5.2", - "phpunit/phpunit": "^9.5" + "nikic/php-parser": "^3.1||^4.13", + "phpdocumentor/reflection-docblock": "^3.0||^4.3||^5.2", + "phpunit/phpunit": "^4.8||^6.5||^9.5" }, "autoload": { "files": ["bottomline.php"], diff --git a/composer.lock b/composer.lock index ddb7408..dcd5dbc 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "fc1b96ca01baadfb7697ee928a3148cd", + "content-hash": "7847d174f90e89731572975fe907b8e5", "packages": [], "packages-dev": [ {