Rename npm script 'prebuild' to 'make-prebuilds' #1
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Prebuild | |
| on: | |
| push: | |
| tags: | |
| - "v*" | |
| workflow_call: | |
| workflow_dispatch: | |
| jobs: | |
| prebuild: | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| include: | |
| - os: ubuntu-latest | |
| arch: x64 | |
| - os: ubuntu-24.04-arm | |
| arch: arm64 | |
| - os: macos-latest | |
| arch: x64+arm64 | |
| - os: windows-latest | |
| arch: x64 | |
| runs-on: ${{ matrix.os }} | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Setup Node.js | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: "20.x" | |
| - name: Install OpenSSL (Ubuntu) | |
| if: runner.os == 'Linux' | |
| run: | | |
| sudo apt-get update | |
| sudo apt-get install -y libssl-dev | |
| - name: Install OpenSSL (macOS) | |
| if: runner.os == 'macOS' | |
| run: brew install openssl | |
| - name: Install OpenSSL (Windows) | |
| if: runner.os == 'Windows' | |
| run: vcpkg install openssl:x64-windows | |
| - name: Set OpenSSL env (Windows) | |
| if: runner.os == 'Windows' | |
| run: echo "OPENSSL_ROOT=$env:VCPKG_INSTALLATION_ROOT\installed\x64-windows" >> $env:GITHUB_ENV | |
| shell: pwsh | |
| - name: Install dependencies | |
| run: npm ci | |
| - name: Prebuild | |
| run: npx prebuildify --napi --strip | |
| - name: Upload prebuilds | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: prebuilds-${{ matrix.os }}-${{ matrix.arch }} | |
| path: prebuilds/ |