-
Notifications
You must be signed in to change notification settings - Fork 46
56 lines (52 loc) · 1.95 KB
/
release.yaml
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
56
on:
push:
tags:
- '*'
workflow_dispatch:
name: Build release artifacts
env:
RUST_BACKTRACE: 1
CARGO_PROFILE_DEV_DEBUG: 0
jobs:
release:
permissions:
contents: write
strategy:
fail-fast: false
matrix:
platform:
- host: macos-latest
target: aarch64-apple-darwin
- host: macos-latest
target: x86_64-apple-darwin
- host: windows-latest
target: x86_64-pc-windows-msvc
runs-on: ${{ matrix.platform.host }}
steps:
- uses: actions/checkout@v4
- name: Setup environment
uses: ./.github/actions/setup-env
- name: Add target
run: rustup target add ${{ matrix.platform.target }}
- uses: apple-actions/import-codesign-certs@v2
if: startsWith(matrix.platform.target, 'aarch64-apple-darwin') || startsWith(matrix.platform.target, 'x86_64-apple-darwin')
with:
p12-file-base64: ${{ secrets.APPLE_CERTIFICATE }}
p12-password: ${{ secrets.APPLE_CERTIFICATE_PASSWORD }}
- name: Verify certificate
if: startsWith(matrix.platform.target, 'aarch64-apple-darwin') || startsWith(matrix.platform.target, 'x86_64-apple-darwin')
run: security find-identity -v -p codesigning ${{ runner.temp }}/build.keychain
- name: Create release
uses: tauri-apps/tauri-action@v0
with:
includeUpdaterJson: true
tagName: v__VERSION__
releaseName: 'v__VERSION__'
args: --target ${{ matrix.platform.target }}
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
APPLE_CERTIFICATE: ${{ secrets.APPLE_CERTIFICATE }}
APPLE_CERTIFICATE_PASSWORD: ${{ secrets.APPLE_CERTIFICATE_PASSWORD }}
APPLE_SIGNING_IDENTITY: ${{ secrets.APPLE_SIGNING_IDENTITY }}
TAURI_SIGNING_PRIVATE_KEY: ${{ secrets.TAURI_UPDATER_PRIVATE_KEY }}
TAURI_SIGNING_PRIVATE_KEY_PASSWORD: ${{ secrets.TAURI_UPDATER_PASSWORD }}