-
Notifications
You must be signed in to change notification settings - Fork 0
55 lines (52 loc) · 1.46 KB
/
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
54
55
name: Build and Release macOS App
on:
push:
tags:
- v*
jobs:
create-release:
runs-on: ubuntu-latest
outputs:
upload_url: ${{ steps.release.outputs.upload_url }}
steps:
- name: Create Release
id: release
uses: actions/create-release@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
tag_name: ${{ github.ref }}
release_name: LANKey ${{ github.ref_name }}
draft: false
prerelease: false
build-macos-app:
needs: create-release
strategy:
matrix:
platform:
- runner: macos-14
arch: arm64
- runner: macos-12
arch: x86_64
runs-on: ${{ matrix.platform.runner }}
steps:
- name: Checkout code
uses: actions/checkout@v2
- name: Set up Python
uses: actions/setup-python@v2
with:
python-version: 3.12
- name: Install dependencies
run: pip install -rrequirements.txt
- name: Build macOS App
run: ./build.sh
- name: Upload Release Asset
id: upload_release_asset
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
asset_name: LANKey.${{ github.ref_name }}.${{ matrix.platform.arch }}.dmg
asset_content_type: application/x-apple-diskimage
upload_url: ${{ needs.create-release.outputs.upload_url }}
asset_path: ./dist/LANKey.dmg