Skip to content

feat: load node library from api fallback to files (#611) #77

feat: load node library from api fallback to files (#611)

feat: load node library from api fallback to files (#611) #77

Workflow file for this run

name: ProductionPublish
on:
push:
branches:
- release/*
workflow_dispatch:
jobs:
publish:
# all published versions are considered "staging" until we release a non-alpha version
environment: prod
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [macos-latest, ubuntu-latest, windows-latest]
steps:
- if: matrix.os == 'ubuntu-latest'
name: Install packages for building
run: |
sudo apt-get install --no-install-recommends -y rpm libarchive-tools
# https://github.com/electron/forge/issues/2807
- if: ${{ matrix.os == 'macos-latest' }}
run: python3 -m pip install setuptools --break-system-packages
- name: Used variables
run: |
echo "MP_PROJECT_ENV variable : ${{ vars.MP_PROJECT_ENV }}"
echo "NICENODE_ENV variable : ${{ vars.NICENODE_ENV }}"
- name: Checkout git repo
uses: actions/checkout@v4
- name: Install Node and NPM
uses: actions/setup-node@v4
with:
node-version: 20
# cache: npm
- name: Install dependencies
run: |
npm ci
- if: ${{ matrix.os == 'macos-latest' }}
name: Import Certs
uses: apple-actions/import-codesign-certs@v3
with:
p12-file-base64: ${{ secrets.CSC_LINK }}
p12-password: ${{ secrets.CSC_KEY_PASSWORD }}
- name: Publish releases
env:
# macOS code signing and notarization
APPLE_ID: ${{ secrets.APPLE_ID }}
APPLE_ID_PASSWORD: ${{ secrets.APPLE_ID_PASSWORD }}
APPLE_APP_SPECIFIC_PASSWORD: ${{ secrets.APPLE_ID_PASSWORD }}
APPLE_TEAM_ID: ${{ secrets.APPLE_TEAM_ID }}
APPLE_PROD_CERT_NAME: ${{ secrets.APPLE_PROD_CERT_NAME }}
CSC_LINK: ${{ secrets.CSC_LINK }}
CSC_KEY_PASSWORD: ${{ secrets.CSC_KEY_PASSWORD }}
WIN_CSC_LINK: ${{ secrets.WIN_CSC_BASE64 }}
WIN_CSC_KEY_PASSWORD: ${{ secrets.WIN_CSC_KEY_PASSWORD_2 }}
# CSC_IDENTITY_AUTO_DISCOVERY: false
# This is used for app event tracking
SENTRY_DSN: ${{ secrets.SENTRY_DSN }}
MP_PROJECT_TOKEN: ${{ secrets.MP_PROJECT_TOKEN }}
MP_PROJECT_ENV: ${{ vars.MP_PROJECT_ENV }}
NICENODE_ENV: ${{ vars.NICENODE_ENV }}
# This is used for uploading release assets to github
GITHUB_TOKEN: ${{ secrets.GH_TOKEN }}
run: |
npm run publish -- --arch=x64
npm run publish -- --arch=arm64