-
Notifications
You must be signed in to change notification settings - Fork 21
53 lines (43 loc) · 1.54 KB
/
manual_macos_release.yml
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
49
50
51
52
53
name: Manual MacOS Release
on:
workflow_dispatch:
jobs:
build:
runs-on: macos-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Python
uses: actions/setup-python@v5
with:
python-version: "3.9"
- name: Get Latest Tag
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
LATEST_TAG=$(gh release list --limit 1 --json tagName --jq '.[0].tagName')
- name: Setup + Build + Zip
run: |
# replace the pyqt requirements in pyproject.toml
sed -i '' 's/pyqt5-qt5==/pyqt5-qt5>=/' pyproject.toml
echo "Venv setup"
python -m venv .venv
source ./.venv/bin/activate
echo "Installing dependencies"
pip install -e ./
echo "Building style"
python build_style.py
echo "Building application"
cd scripts
bash build_mac.sh
echo "Zipping to Blender_Launcher_${{ env.LATEST_TAG }}_macos_arm64.zip"
cd ../dist/release
# this zips just like the one in finder
ditto -c -k --sequesterRsrc --keepParent "Blender Launcher.app" "Blender_Launcher_${{ env.LATEST_TAG }}_macos_arm64.zip"
mv "Blender_Launcher_${{ env.LATEST_TAG }}_macos_arm64.zip" ../..
cd ../..
- name: Upload to Latest Release
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
gh release upload "${{ env.LATEST_TAG }}" ./Blender_Launcher_"${{ env.LATEST_TAG }}"_macos_arm64.zip