Skip to content

Tasks

Tasks #16

Workflow file for this run

name: Tasks
on:
push:
branches: "*"
schedule:
- cron: '0 0 * * *'
jobs:
lint-php:
name: "php: ${{ matrix.php }} ${{ matrix.prefer-lowest }}"
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
php: [ '8.1', '8.2', '8.3' ]
prefer-lowest: ['--prefer-lowest', '']
steps:
- name: Setup PHP with PECL extension
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php }}
- uses: actions/checkout@v2
- name: Get Composer Cache Directory
id: composer-cache
run: |
echo "dir=$(composer config cache-files-dir)" >> $GITHUB_OUTPUT
- uses: actions/cache@v3
with:
path: ${{ steps.composer-cache.outputs.dir }}
key: ${{ runner.os }}-${{ matrix.php }}-${{ matrix.prefer-lowest }}-composer-${{ hashFiles('**/composer.lock') }}
restore-keys: |
${{ runner.os }}-${{ matrix.php }}-${{ matrix.prefer-lowest }}-composer
- run: composer update ${{ matrix.prefer-lowest }} --no-interaction --no-progress
- run: ./vendor/bin/grumphp run --ansi