-
Notifications
You must be signed in to change notification settings - Fork 4
48 lines (36 loc) · 1.23 KB
/
Copy pathrelease-macos.yml
File metadata and controls
48 lines (36 loc) · 1.23 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
name: Release (macOS)
# Separate from the Windows release so a macOS failure doesn't block Windows builds.
# macOS builds are unsigned — users must right-click > Open to bypass Gatekeeper.
on:
push:
tags: ["v*"]
permissions:
contents: write
jobs:
build-macos:
runs-on: macos-latest
steps:
- uses: actions/checkout@v4
- name: Set up Python 3.12
uses: actions/setup-python@v5
with:
python-version: "3.12"
- name: Install dependencies
run: pip install ".[dev]"
- name: Run tests
run: pytest -q --tb=short
- name: Build macOS app
run: python -m PyInstaller spirescope.spec --clean --noconfirm
- name: Strip dist-info metadata
run: find dist/Spirescope -name "*.dist-info" -type d -exec rm -rf {} +
- name: Create zip archive
run: |
cd dist
zip -r Spirescope-${{ github.ref_name }}-macos.zip Spirescope/
cp Spirescope-${{ github.ref_name }}-macos.zip Spirescope-macos.zip
- name: Upload to existing release
uses: softprops/action-gh-release@v2
with:
files: |
dist/Spirescope-${{ github.ref_name }}-macos.zip
dist/Spirescope-macos.zip