Skip to content

Analysis

Analysis #377

Workflow file for this run

name: Analysis
on:
push:
branches:
- main
- '*.x'
pull_request:
schedule:
- cron: '0 5 * * *'
jobs:
static-analysis:
name: "Run static analysis with P${{ matrix.php }} and ${{ matrix.dependency-version }} dependencies"
runs-on: ubuntu-latest
strategy:
fail-fast: true
matrix:
php:
- "8.2"
- "8.3"
- "8.4"
dependency-version:
- "prefer-lowest"
- "prefer-stable"
steps:
- uses: "actions/checkout@v4"
- uses: "shivammathur/setup-php@v2"
with:
php-version: "${{ matrix.php }}"
- name: Install dependencies
run: composer update --${{ matrix.dependency-version }} --prefer-dist --no-interaction
- name: Run PHPStan
run: ./vendor/bin/phpstan analyse --error-format=github --configuration="./dev/config/phpstan.neon"
format:
name: "Check format with P${{ matrix.php }} and ${{ matrix.dependency-version }} dependencies"
runs-on: ubuntu-latest
strategy:
fail-fast: true
matrix:
php:
- "8.3"
dependency-version:
- "prefer-stable"
steps:
- uses: "actions/checkout@v4"
- uses: "shivammathur/setup-php@v2"
with:
php-version: "${{ matrix.php }}"
- name: Install dependencies
run: composer update --${{ matrix.dependency-version }} --prefer-dist --no-interaction
- name: Run PHP-CS-Fixer
run: ./vendor/bin/php-cs-fixer check --config="./dev/config/php-cs-fixer.php"
markdown:
name: "Lint markdown files"
runs-on: ubuntu-latest
steps:
- uses: "actions/checkout@v4"
- uses: DavidAnson/markdownlint-cli2-action@v19
with:
config: 'dev/config/.markdownlint.jsonc'
globs: |
**/*.md
!CHANGELOG.md