Skip to content

rly is building a MAC release for NWB GUIDE #11

rly is building a MAC release for NWB GUIDE

rly is building a MAC release for NWB GUIDE #11

name: Mac Release
run-name: ${{ github.actor }} is building a MAC release for NWB GUIDE
# NOTE: even though the runner is an x64 mac, both x64 and arm64 releases will be made
on:
workflow_dispatch:
jobs:
deploy-on-mac:
runs-on: macos-13
# not using macos-latest because that runner is an arm64 mac and there are issues
# building and deploying with sonpy (Spike2RecordingInterface) on arm64 mac
defaults:
run:
shell: bash -l {0}
steps:
- uses: actions/checkout@v3
- uses: actions/setup-python@v4
with:
python-version: "3.10"
- name: Setup Mambaforge
uses: conda-incubator/setup-miniconda@v3
with:
miniforge-variant: Mambaforge
miniforge-version: latest
activate-environment: nwb-guide
use-mamba: true
- name: Create and activate environment
run: mamba env update --name nwb-guide --file environments/environment-MAC-apple-silicon.yml
- name: Use Node.js 20
uses: actions/setup-node@v4
with:
node-version: 20
- name: Install package.json modules and their dependencies (not via `npm ci`)
run: npm install --verbose
- name: Remove bad sonpy file (might make Spike2 format unusable on Mac - should exclude from selection)
run: rm -f "$CONDA_PREFIX/lib/python3.9/site-packages/sonpy/linux/sonpy.so"
- uses: apple-actions/import-codesign-certs@v2
with:
# Currently this is set to Ryan's Developer ID certificate
p12-file-base64: ${{ secrets.MACOS_CERTIFICATE }}
p12-password: ${{ secrets.MACOS_CERTIFICATE_PWD }}
- name: Build and deploy on MAC
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
# Currently this is set to Ryan's Apple ID and app-specific password
teamId: ${{ secrets.APPLE_TEAM_ID }}
appleId: ${{ secrets.APPLE_ID }}
appleIdPassword: ${{ secrets.APPLE_PASSWORD }}
run: npm run deploy:mac