-
Notifications
You must be signed in to change notification settings - Fork 0
67 lines (57 loc) · 1.92 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
56
57
58
59
60
61
62
63
64
65
66
67
name: Create Release on Successful Builds
on:
workflow_run:
workflows: ["Run Build Lint and test Next.js app", "Run Build and test Tauri App"]
types:
- completed
push:
tags:
- "v*"
permissions:
contents: write
jobs:
bootstrap:
runs-on: ubuntu-latest
steps:
- name: Initialize Release Workflow
run: echo "Bootstrap job to satisfy GitHub's dependency rules."
release:
runs-on: ubuntu-latest
if: ${{ github.event.workflow_run.conclusion == 'success' }}
# needs: ["Run Build Lint and test Next.js app", "Run Build and test Tauri App"]
steps:
- name: Checkout Repository
uses: actions/checkout@v4
- name: Download Next.js Build Artifact
uses: actions/download-artifact@v4
with:
name: nextjs-build-success
- name: Download Tauri Build Artifact
uses: actions/download-artifact@v4
with:
name: tauri-build-success
# - name: Create GitHub Release
# id: create_release
# uses: actions/create-release@v1
# with:
# tag_name: ${{ github.sha }}
# release_name: "Release ${{ github.sha }}"
# body: "Automated release for commit ${{ github.sha }}."
# draft: false
# prerelease: false
- name: Create GitHub Release
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
tag: ${{ github.ref_name }}
run: |
gh release create "$tag" \
--repo="$GITHUB_REPOSITORY" \
--title="${tag#v}" \
--generate-notes
- name: Upload Tauri Binaries (for Windows, macOS, Linux)
uses: actions/upload-release-asset@v1
with:
upload_url: ${{ steps.create_release.outputs.upload_url }}
asset_path: ./tauri-app/target/release/bundle/*.app
asset_name: TauriApp-${{ github.sha }}.zip
asset_content_type: application/zip