Merge pull request #1 from webmasterskaya/test-workflows

Настроен статический анализ кода
This commit is contained in:
Artem Vasilev 2022-11-10 14:30:27 +03:00 committed by GitHub
commit 612031c8dc
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 11 additions and 8 deletions

View File

@ -1,8 +1,10 @@
name: "Static analysis code"
on:
- push
- pull_request
push:
branches:
- master
pull_request:
env:
COMPOSER_FLAGS: "--ansi --prefer-dist --no-interaction --no-progress"
@ -24,7 +26,7 @@ jobs:
steps:
- name: "Checkout"
uses: "actions/checkout@v2"
uses: "actions/checkout@v3"
- name: "Install PHP"
uses: "shivammathur/setup-php@v2"
@ -49,13 +51,13 @@ jobs:
- "7.4"
steps:
- name: "Cancel Previous Runs"
uses: styfle/cancel-workflow-action@0.9.0
uses: styfle/cancel-workflow-action@0.11.0
with:
all_but_latest: true
access_token: ${{ github.token }}
- name: "Checkout"
uses: "actions/checkout@v2"
uses: "actions/checkout@v3"
- name: "Install PHP"
uses: "shivammathur/setup-php@v2"
@ -81,7 +83,7 @@ jobs:
run: |
composer install ${{ env.COMPOSER_FLAGS }}
rm composer.lock
composer config platform.php ${{ matrix.php }}
composer config platform.php ${{ matrix.php-version }}
- name: Run phpstan
run: composer phpstan

View File

@ -29,7 +29,7 @@
}
],
"require": {
"php": "=>7.2 <8.0",
"php": ">=7.2 <8.0",
"ext-mbstring": "*"
},
"require-dev": {

1
tmp/src.txt Executable file
View File

@ -0,0 +1 @@
foo bar master