Merge branch 'devel' into master #141
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: PHPStan | |
on: | |
push: | |
pull_request: | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/[email protected] | |
- name: Change PHP version | |
run: | | |
sudo update-alternatives --set php /usr/bin/php8.0 | |
sudo update-alternatives --set phar /usr/bin/phar8.0 | |
sudo update-alternatives --set phpdbg /usr/bin/phpdbg8.0 | |
sudo update-alternatives --set php-cgi /usr/bin/php-cgi8.0 | |
sudo update-alternatives --set phar.phar /usr/bin/phar.phar8.0 | |
php -version | |
- name: Validate composer.json and composer.lock | |
run: composer validate | |
- name: Cache Composer packages | |
id: composer-cache | |
uses: actions/[email protected] | |
with: | |
path: vendor | |
key: ${{ runner.os }}-php-${{ hashFiles('**/composer.lock') }} | |
restore-keys: | | |
${{ runner.os }}-php- | |
- name: Install dependencies | |
if: steps.composer-cache.outputs.cache-hit != 'true' | |
run: composer install --prefer-dist --no-progress --no-suggest | |
- name: Run phpstan | |
run: composer run-script phpstan |