-
-
Notifications
You must be signed in to change notification settings - Fork 159
44 lines (36 loc) · 1.16 KB
/
code-style.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
42
43
44
name: Code Style
on: [pull_request]
jobs:
phpcs:
name: phpcs
runs-on: ubuntu-latest
steps:
- name: Check out code into the workspace
uses: actions/checkout@v2
- name: Install php
uses: shivammathur/setup-php@v2
with:
php-version: "5.6"
- name: Install dependencies
run: composer update --dev --no-interaction --prefer-dist --no-progress --no-suggest --ansi
- name: PHPCS check
uses: chekalsky/phpcs-action@v1
with:
phpcs_bin_path: './vendor/bin/phpcs'
enable_warnings: true
phpstan:
name: phpstan
runs-on: ubuntu-latest
steps:
- name: Check out code into the workspace
uses: actions/checkout@v2
- name: Install php
uses: shivammathur/setup-php@v2
with:
php-version: "7.4"
- name: Install dependencies
run: composer update --dev --no-interaction --prefer-dist --no-progress --no-suggest --ansi
- name: Require phpstan
run: composer require --dev phpstan/phpstan --no-interaction
- name: Run phpstan
run: php ./vendor/phpstan/phpstan/phpstan.phar analyse --no-progress