Skip to content

1.4.0

1.4.0 #7

Workflow file for this run

name: Release
on:
push:
tags: ['*']
jobs:
build:
permissions:
contents: read
strategy:
matrix:
include:
- os: ubuntu-latest
arch: x64
build-group: linux-x64
- os: ubuntu-latest
arch: x64
build-group: linux-arm
- os: ubuntu-latest
arch: x64
build-group: android-arm
# At the time of writing macos-latest is mac 10; we need 11 to build a universal binary.
- os: macos-11
arch: x64
build-group: darwin-x64+arm64
- os: windows-latest
arch: x86
build-group: win32-x86
- os: windows-latest
arch: x64
build-group: win32-x64
runs-on: ${{ matrix.os }}
name: Build ${{ matrix.build-group }}
env:
BUILD_GROUP: ${{ matrix.build-group }}
steps:
- name: Checkout
uses: actions/checkout@v3
with:
submodules: recursive
- name: Set up node
uses: actions/setup-node@v3
with:
node-version: 14
architecture: ${{ matrix.arch }}
# Temporary fix for https://github.com/nodejs/node-gyp/issues/2869
# TODO: instead bump node-gyp to >= 10.0.0 (drops Node.js < 16.14)
- name: Use Python 3.11
uses: actions/setup-python@v4
with:
python-version: '3.11'
- name: Install
run: npm install --ignore-scripts
- name: Prebuild
run: npm run prebuild-$BUILD_GROUP
shell: bash
- name: Prepare artifact
run: tar -zcvf $BUILD_GROUP.tar.gz -C prebuilds .
shell: bash
- name: Upload artifact
uses: actions/upload-artifact@v3
with:
name: ${{ env.BUILD_GROUP }}
path: ${{ env.BUILD_GROUP }}.tar.gz
retention-days: 1
release:
needs: build
permissions:
contents: write
runs-on: ubuntu-latest
name: Release
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Download artifacts
uses: actions/download-artifact@v3
with:
path: artifacts
- name: Create GitHub release
uses: docker://antonyurchenko/git-release:v4
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
args: artifacts/*/*.tar.gz