Skip to content

chore: Add information regarding dependency version locks due to comp… #30

chore: Add information regarding dependency version locks due to comp…

chore: Add information regarding dependency version locks due to comp… #30

Workflow file for this run

name: Build packages
on:
push:
branches: [ main ]
tags: [ '*' ]
pull_request:
branches: [ main ]
workflow_dispatch:
jobs:
build-darwin:
runs-on: macos-latest
strategy:
matrix:
arch: [arm64, universal, x64]
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: 22
check-latest: true
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: '3.12'
check-latest: true
- name: Install dependencies
run: |
python3 -m pip install setuptools
npm install
- name: Build package
env:
APPLE_ID_PASSWORD: ${{ secrets.APPLE_ID_PASSWORD }}
APPLE_ID: ${{ secrets.APPLE_ID }}
APPLE_TEAM_ID: ${{ secrets.APPLE_TEAM_ID }}
CASTLABS_EVS_PASSWORD: ${{ secrets.CASTLABS_EVS_PASSWORD }}
CASTLABS_EVS_USERNAME: ${{ secrets.CASTLABS_EVS_USERNAME }}
CI_KEYCHAIN_PASSWORD: ${{ secrets.CI_KEYCHAIN_PASSWORD }}
CODESIGN_CERTIFICATE_PASSWORD: ${{ secrets.CODESIGN_CERTIFICATE_PASSWORD }}
CODESIGN_CERTIFICATE: ${{ secrets.CODESIGN_CERTIFICATE }}
run: |
echo $CODESIGN_CERTIFICATE | base64 --decode > Certificates.p12
security create-keychain -p "$CI_KEYCHAIN_PASSWORD" build.keychain
security default-keychain -s build.keychain
security unlock-keychain -p "$CI_KEYCHAIN_PASSWORD" build.keychain
security import Certificates.p12 -k build.keychain -P "$CODESIGN_CERTIFICATE_PASSWORD" -T /usr/bin/codesign
security set-key-partition-list -S apple-tool:,apple:,codesign: -s -k "$CI_KEYCHAIN_PASSWORD" build.keychain
npm run make -- --platform darwin --arch ${{ matrix.arch }}
- name: Upload package (DMG)
uses: actions/upload-artifact@v4
with:
name: eXViewer-darwin-${{ matrix.arch }}-Installer
path: out/make/*.dmg
if-no-files-found: error
compression-level: 9
- name: Upload package (ZIP)
uses: actions/upload-artifact@v4
with:
name: eXViewer-darwin-${{ matrix.arch }}
path: out/make/zip/darwin/${{ matrix.arch }}/*
if-no-files-found: error
compression-level: 9
build-linux:
runs-on: ubuntu-latest
strategy:
matrix:
arch: [x64]
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: 21
check-latest: true
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: '3.12'
check-latest: true
- name: Install dependencies
run: npm install
- name: Build package
env:
CASTLABS_EVS_USERNAME: ${{ secrets.CASTLABS_EVS_USERNAME }}
CASTLABS_EVS_PASSWORD: ${{ secrets.CASTLABS_EVS_PASSWORD }}
run: npm run package -- --platform linux --arch ${{ matrix.arch }}
- name: Upload package
uses: actions/upload-artifact@v4
with:
name: eXViewer-linux-${{ matrix.arch }}
path: out/eXViewer-linux-${{ matrix.arch }}/
if-no-files-found: error
compression-level: 9
build-win32:
runs-on: windows-latest
strategy:
matrix:
arch: [x64, ia32]
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: 21
check-latest: true
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: '3.12'
check-latest: true
- name: Install dependencies
run: npm install
- name: Build package
env:
CASTLABS_EVS_USERNAME: ${{ secrets.CASTLABS_EVS_USERNAME }}
CASTLABS_EVS_PASSWORD: ${{ secrets.CASTLABS_EVS_PASSWORD }}
run: npm run package -- --platform win32 --arch ${{ matrix.arch }}
- name: Upload package
uses: actions/upload-artifact@v4
with:
name: eXViewer-win32-${{ matrix.arch }}
path: out/eXViewer-win32-${{ matrix.arch }}/
if-no-files-found: error
compression-level: 9