Skip to content

Commit

Permalink
gactions: run PHPStan check
Browse files Browse the repository at this point in the history
  • Loading branch information
hrach committed Oct 11, 2020
1 parent ed07db2 commit df0ba29
Showing 1 changed file with 37 additions and 0 deletions.
37 changes: 37 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
name: "Build"

on:
pull_request:
push:

jobs:
phpstan:
name: PHPStan

runs-on: ubuntu-latest

steps:
- name: Checkout
uses: actions/checkout@v2

- name: Setup PHP with pecl extension
uses: shivammathur/setup-php@v2
with:
php-version: '7.4'

- name: Get composer cache directory
id: composercache
run: echo "::set-output name=dir::$(composer config cache-files-dir)"

- name: Cache dependencies
uses: actions/cache@v2
with:
path: ${{ steps.composercache.outputs.dir }}
key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.lock') }}
restore-keys: ${{ runner.os }}-composer-

- name: Install dependencies
run: composer install --prefer-dist

- name: Run PHPStan
run: composer phpstan

0 comments on commit df0ba29

Please sign in to comment.