mirror of
https://github.com/rectorphp/rector.git
synced 2024-06-03 09:50:49 +00:00
55 lines
1.6 KiB
YAML
55 lines
1.6 KiB
YAML
name: Code Analysis
|
|
|
|
on:
|
|
pull_request: null
|
|
|
|
env:
|
|
# see https://github.com/composer/composer/issues/9368#issuecomment-718112361
|
|
COMPOSER_ROOT_VERSION: "dev-main"
|
|
|
|
jobs:
|
|
code_analysis:
|
|
strategy:
|
|
fail-fast: false
|
|
matrix:
|
|
actions:
|
|
-
|
|
name: 'Composer Validate'
|
|
run: composer validate --ansi
|
|
|
|
-
|
|
name: 'Validate Max File Length'
|
|
run: vendor/bin/easy-ci validate-file-length packages rules src tests
|
|
|
|
-
|
|
name: 'PHPStan'
|
|
run: vendor/bin/phpstan analyse --ansi --error-format symplify
|
|
|
|
-
|
|
name: 'PHPStan for config'
|
|
run: composer phpstan-config
|
|
|
|
# see https://github.com/rectorphp/rector-generator
|
|
-
|
|
name: 'Rector Generate From Recipe'
|
|
run: |
|
|
bin/rector init-recipe --ansi
|
|
bin/rector generate --ansi
|
|
|
|
name: ${{ matrix.actions.name }}
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
- uses: actions/checkout@v2
|
|
|
|
# see https://github.com/shivammathur/setup-php
|
|
-
|
|
uses: shivammathur/setup-php@v2
|
|
with:
|
|
php-version: 8.0
|
|
coverage: none
|
|
|
|
- uses: "ramsey/composer-install@v1"
|
|
|
|
- run: ${{ matrix.actions.run }}
|