ci: add eslint.yml

This commit is contained in:
Maël Gangloff
2024-12-31 00:06:44 +01:00
parent 20db897890
commit 950106bf61
2 changed files with 39 additions and 6 deletions

View File

@@ -16,6 +16,14 @@ jobs:
- name: Checkout code
uses: actions/checkout@v3
- name: Cache Composer dependencies
uses: actions/cache@v3
with:
path: vendor
key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.lock') }}
restore-keys: |
${{ runner.os }}-composer-
- name: Set up PHP
uses: shivammathur/setup-php@v2
with:
@@ -25,14 +33,8 @@ jobs:
- name: Install backend dependencies
run: composer install --prefer-dist --no-progress --no-suggest --optimize-autoloader
- name: Install frontend dependencies
run: yarn install
- name: Run PHP-CS-Fixer
run: vendor/bin/php-cs-fixer fix --dry-run --diff
- name: Run PHPStan
run: vendor/bin/phpstan analyse
- name: Run ESLint
run: yarn run eslint