Commit b46e86e4 authored by Ben Davies's avatar Ben Davies

move phpcs from travis to GitHub Actions

parent bc9d8cac
...@@ -28,11 +28,44 @@ jobs: ...@@ -28,11 +28,44 @@ jobs:
uses: "actions/cache@v1" uses: "actions/cache@v1"
with: with:
path: "~/.composer/cache" path: "~/.composer/cache"
key: "${{ matrix.php-version }}-composer-locked-${{ hashFiles('composer.lock') }}" key: "php-${{ matrix.php-version }}-composer-locked-${{ hashFiles('composer.lock') }}"
restore-keys: "${{ matrix.php-version }}-composer-locked-" restore-keys: "php-${{ matrix.php-version }}-composer-locked-"
- name: "Install dependencies with composer" - name: "Install dependencies with composer"
run: "composer install --no-interaction --no-progress --no-suggest" run: "composer install --no-interaction --no-progress --no-suggest"
- name: "Psalm" - name: "Psalm"
run: "vendor/bin/psalm" run: "vendor/bin/psalm"
coding-standards:
name: "Coding Standards"
runs-on: "ubuntu-latest"
strategy:
matrix:
php-version:
- "7.4"
steps:
- name: "Checkout"
uses: "actions/checkout@v2"
- name: "Install PHP"
uses: "shivammathur/setup-php@v2"
with:
coverage: "none"
php-version: "${{ matrix.php-version }}"
tools: "cs2pr"
- name: "Cache dependencies installed with composer"
uses: "actions/cache@v1"
with:
path: "~/.composer/cache"
key: "php-${{ matrix.php-version }}-composer-locked-${{ hashFiles('composer.lock') }}"
restore-keys: "php-${{ matrix.php-version }}-composer-locked-"
- name: "Install dependencies with composer"
run: "composer install --no-interaction --no-progress --no-suggest"
- name: "Run squizlabs/php_codesniffer"
run: "vendor/bin/phpcs -q --no-colors --report=checkstyle | cs2pr"
...@@ -49,11 +49,6 @@ jobs: ...@@ -49,11 +49,6 @@ jobs:
env: PHPStan env: PHPStan
install: travis_retry composer install --prefer-dist install: travis_retry composer install --prefer-dist
script: vendor/bin/phpstan analyse script: vendor/bin/phpstan analyse
- stage: Smoke Testing
php: 7.3
env: PHP_CodeSniffer
install: travis_retry composer install --prefer-dist
script: vendor/bin/phpcs
- stage: Test - stage: Test
php: 7.2 php: 7.2
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment