.github/workflows/rector.yaml
name: Rector
on:
push:
branches: [main]
pull_request:
branches: [main]
jobs:
rector:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Rector Cache
uses: actions/cache@v4
with:
path: /tmp/rector
key: ${{ runner.os }}-rector-${{ github.run_id }}
restore-keys: ${{ runner.os }}-rector-
- run: mkdir -p /tmp/rector
- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: 8.2
coverage: none
- name: Install composer dependencies
uses: ramsey/composer-install@v3
- name: Rector Dry Run
run: php vendor/bin/rector process --dry-run --config=rector.php