Skip to content

Commit

Permalink
fix(eslint): adjust workflow too
Browse files Browse the repository at this point in the history
Signed-off-by: John Molakvoæ <skjnldsv@protonmail.com>
  • Loading branch information
skjnldsv committed Feb 1, 2024
1 parent 0d07c16 commit 2288a5b
Showing 1 changed file with 22 additions and 13 deletions.
35 changes: 22 additions & 13 deletions .github/workflows/eslint.yml
Original file line number Diff line number Diff line change
@@ -1,31 +1,40 @@
name: Lint

on: pull_request
on:
pull_request:
push:
branches:
- main

permissions:
contents: read

concurrency:
group: eslint-${{ github.head_ref || github.run_id }}
concurrency:
group: lint-${{ github.head_ref || github.run_id }}
cancel-in-progress: true

jobs:
build:
eslint:
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [14, 16, 18]
# See supported Node.js release schedule at https://nodejs.org/en/about/releases/

name: eslint
steps:
- name: Checkout
uses: actions/checkout@v3
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1

- name: Set up node ${{ matrix.node-version }}
uses: actions/setup-node@v3
- name: Read package.json node and npm engines version
uses: skjnldsv/read-package-engines-version-actions@8205673bab74a63eb9b8093402fd9e0e018663a1 # v2.2
id: versions
with:
node-version: ${{ matrix.node-version }}
fallbackNode: '^20'
fallbackNpm: '^10'

- name: Set up node ${{ steps.versions.outputs.nodeVersion }}
uses: actions/setup-node@b39b52d1213e96004bfcb1c61a8a6fa8ab84f3e8 # v3
with:
node-version: ${{ steps.versions.outputs.nodeVersion }}

- name: Set up npm ${{ steps.versions.outputs.npmVersion }}
run: npm i -g npm@"${{ steps.versions.outputs.npmVersion }}"

- name: Install dependencies
run: npm ci
Expand Down

0 comments on commit 2288a5b

Please sign in to comment.