Skip to content

Merge branch 'refs/heads/6.x' into feature/MTCE-226-Monorepo-v6-refac… #2408

Merge branch 'refs/heads/6.x' into feature/MTCE-226-Monorepo-v6-refac…

Merge branch 'refs/heads/6.x' into feature/MTCE-226-Monorepo-v6-refac… #2408

Workflow file for this run

name: PHP-CI
on: [push, pull_request]
jobs:
coding_standards:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
php: ['8.2']
actions:
- {name: composer, run: make check-composer}
- {name: monorepo, run: make check-monorepo}
- {name: security, run: make check-security}
- {name: ecs, run: make check-ecs, cache: ecs}
- {name: rector, run: make check-rector, cache: rector}
- {name: phpstan, run: make check-phpstan, cache: phpstan}
name: ${{ matrix.actions.name }} (${{ matrix.php }})
env:
PHP_EXTENSIONS: pdo_sqlite, openswoole, pkcs11
PHP_EXTENSIONS_CACHE_KEY: cache-extensions-pdo_sqlite-openswoole-pkcs11
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup cache environment
id: cache-extensions
uses: shivammathur/cache-extensions@v1
with:
php-version: ${{ matrix.php }}
extensions: ${{ env.PHP_EXTENSIONS }}
key: ${{ env.PHP_EXTENSIONS_CACHE_KEY }}
- name: Cache extensions
uses: actions/cache@v4
with:
path: ${{ steps.cache-extensions.outputs.dir }}
key: ${{ steps.cache-extensions.outputs.key }}
restore-keys: ${{ steps.cache-extensions.outputs.key }}
- name: Setup PHP ${{ matrix.php }}
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php }}
coverage: ${{ matrix.actions.coverage || 'none' }}
extensions: ${{ env.PHP_EXTENSIONS }}
- name: Install Composer dependencies
uses: ramsey/composer-install@v3
- name: Install Composer dependencies for Quality Tools
uses: ramsey/composer-install@v3
with:
working-directory: quality
- if: matrix.actions.cache
id: cache-quality-tools
uses: actions/cache@v4
with:
path: quality/var/cache/${{ matrix.actions.cache }}
key: ${{ runner.os }}-${{ matrix.php }}-quality-${{ matrix.actions.name }}-${{ github.sha }}
restore-keys: ${{ runner.os }}-${{ matrix.php }}-quality-${{ matrix.actions.name }}-
- if: matrix.actions.cache && steps.cache-quality-tools.outputs.cache-hit == false
run: mkdir -p ${{ matrix.actions.cache }}
- name: '[CI] Check ${{ matrix.actions.name }} [CI]'
run: ${{ matrix.actions.run }}
shell: bash