2024-05-08 09:17:48 +00:00
|
|
|
# Lint PRs and pushes to the main branch
|
2024-03-20 12:00:56 +00:00
|
|
|
|
2024-05-08 09:17:48 +00:00
|
|
|
name: Lint
|
2024-03-20 12:00:56 +00:00
|
|
|
|
|
|
|
env:
|
|
|
|
NODE_VERSION: 21.x
|
|
|
|
# See supported Node.js release schedule at https://nodejs.org/en/about/releases/
|
|
|
|
|
|
|
|
on:
|
|
|
|
push:
|
|
|
|
branches: [ "main" ]
|
|
|
|
pull_request:
|
|
|
|
branches: [ "main" ]
|
|
|
|
|
|
|
|
jobs:
|
2024-05-08 09:17:48 +00:00
|
|
|
build:
|
2024-03-20 12:00:56 +00:00
|
|
|
runs-on: ubuntu-latest
|
|
|
|
|
|
|
|
steps:
|
|
|
|
- uses: actions/checkout@v4
|
|
|
|
- name: Use Node.js ${{ env.NODE_VERSION }}
|
|
|
|
uses: actions/setup-node@v4
|
|
|
|
with:
|
|
|
|
node-version: ${{ env.NODE_VERSION }}
|
|
|
|
cache: 'npm'
|
|
|
|
cache-dependency-path: ./package-lock.json
|
2024-05-08 09:17:48 +00:00
|
|
|
- name: Install dependencies
|
|
|
|
run: npm ci
|
|
|
|
- name: Run ESLint
|
|
|
|
run: npx eslint
|
|
|
|
- name: Check translations
|
|
|
|
if: '!cancelled()'
|
|
|
|
run: npm run check-translations
|