-
Notifications
You must be signed in to change notification settings - Fork 74
41 lines (38 loc) · 1.48 KB
/
phpstan.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
name: phpstan
# This test will run on every pull request, and on every commit on any branch
on:
push:
branches:
- main
pull_request:
schedule:
# Run tests every week (to check for rector changes)
- cron: '0 0 * * 0'
jobs:
run_static_analysis_phpstan_analyze:
name: Static analysis with PHPStan
# START: SHARED SETUP
runs-on: ubuntu-latest
strategy:
matrix:
include:
- php-version: "8.2"
rector: "^1"
phpstan-config: phpstan-1.neon
- php-version: "8.2"
rector: "^2"
phpstan-config: phpstan.neon
steps:
- uses: actions/checkout@v3
- uses: shivammathur/setup-php@v2
with:
php-version: 8.2
coverage: none # disable xdebug, pcov
tools: composer:v2
extensions: dom, curl, libxml, mbstring, zip, pdo, mysql, pdo_mysql, bcmath, gd, exif, iconv
# Uncomment to enable SSH access to Github Actions - https://github.com/marketplace/actions/debugging-with-tmate#getting-started
# - name: Debugging with tmate
# uses: mxschmitt/action-tmate@v2
# END: SHARED SETUP
- run: composer require rector/rector:${{ matrix.rector }} --dev
- run: vendor/bin/phpstan analyse -c ${{ matrix.phpstan-config }}