-
Notifications
You must be signed in to change notification settings - Fork 0
46 lines (38 loc) · 1.37 KB
/
Copy pathci.yml
File metadata and controls
46 lines (38 loc) · 1.37 KB
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
42
43
44
45
46
name: CI
on:
push:
branches: [master, main]
pull_request:
workflow_dispatch:
jobs:
build:
name: Node ${{ matrix.node }} on ${{ matrix.os }}
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
# macos-latest is arm64, which is exactly the configuration that could not
# build before Lua was vendored.
os: [ubuntu-latest, macos-latest, windows-latest]
node: [20, 22, 24]
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node }}
# The node-gyp bundled with npm on Node 20 and 22 cannot detect Visual
# Studio 18, which is what the windows-latest image now ships, and bails
# with 'unknown version "undefined"'. Node 24 already carries a new enough
# node-gyp. Point npm at a current one so every Node version can build.
- name: Use a current node-gyp on Windows
if: runner.os == 'Windows'
run: |
npm install -g node-gyp@latest
npm config set node_gyp "$(npm prefix -g)/node_modules/node-gyp/bin/node-gyp.js"
# Compiles the addon along with the vendored Lua and LuaFileSystem sources.
- name: Install and build
run: npm install
- name: Test
run: npm test
- name: Check the published tarball contents
run: npm pack --dry-run