forked from mapbox/node-or-tools
-
Notifications
You must be signed in to change notification settings - Fork 1
40 lines (37 loc) · 1.17 KB
/
Build.yml
File metadata and controls
40 lines (37 loc) · 1.17 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
name: Build
on:
release:
types: [created]
workflow_dispatch:
env:
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
AWS_DEFAULT_REGION: eu-central-1
jobs:
Build:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
node-version: [18, 20, 22, 24]
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}
registry-url: https://npm.pkg.github.com/
- name: Install clang
run: sudo apt-get -y install clang
- name: Install meson
run: |
mkdir -p ./third_party/mason
curl -sSfL https://github.com/mapbox/mason/archive/v0.19.0.tar.gz | tar --gunzip --extract --strip-components=1 --directory=./third_party/mason
- name: Build
run: CC='clang' CXX='clang++' npm install --build-from-source
- name: Package
run: ./node_modules/.bin/node-pre-gyp package publish
- name: Publish npm
if: ${{ matrix.node-version == 24 }}
run: npm publish
env:
NODE_AUTH_TOKEN: ${{secrets.GITHUB_TOKEN}}