-
-
Notifications
You must be signed in to change notification settings - Fork 81
41 lines (36 loc) · 941 Bytes
/
node.js.yml
File metadata and controls
41 lines (36 loc) · 941 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
name: Node.js CI
on:
push:
branches: [master, main]
pull_request:
types: [opened, synchronize, reopened]
permissions:
contents: read
jobs:
ubuntu:
needs: [get-lts]
runs-on: ubuntu-latest
strategy:
matrix:
node-version: ${{ fromJson(needs.get-lts.outputs.lts) }}
steps:
- uses: actions/checkout@v6
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v6
with:
node-version: ${{ matrix.node-version }}
- run: npm ci
- run: npm test
get-lts:
runs-on: ubuntu-latest
permissions:
contents: read
steps:
- id: get
uses: msimerson/node-lts-versions@v1
outputs:
active: ${{ steps.get.outputs.active }}
maintenance: ${{ steps.get.outputs.maintenance }}
lts: ${{ steps.get.outputs.lts }}
current: ${{ steps.get.outputs.current }}
min: ${{ steps.get.outputs.min }}