-
Notifications
You must be signed in to change notification settings - Fork 0
34 lines (28 loc) · 893 Bytes
/
lint.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
name: Lint
on: pull_request
jobs:
php-cs-fixer:
runs-on: ubuntu-latest
strategy:
# do not stop on another job's failure
fail-fast: false
matrix:
php-versions: ['7.4', '8.0' , '8.1']
include:
- php-versions: '8.2'
PHP_CS_FIXER_IGNORE_ENV: 1
name: php-cs check php${{ matrix.php-versions }}
steps:
- name: Checkout
uses: actions/checkout@master
- name: Set up php
uses: shivammathur/setup-php@master
with:
php-version: ${{ matrix.php-versions }}
coverage: none
- name: Install dependencies
run: composer i
- name: Run coding standards check
env:
PHP_CS_FIXER_IGNORE_ENV: ${{ matrix.PHP_CS_FIXER_IGNORE_ENV }}
run: composer run cs:check || ( echo 'Please run `composer run cs:fix` to format your code' && exit 1 )