-
Notifications
You must be signed in to change notification settings - Fork 1
112 lines (110 loc) · 3.53 KB
/
build.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
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
name: Build
on:
workflow_dispatch:
inputs:
tag:
description: 'Tag Name'
required: true
prerelease:
description: 'Prerelease'
type: boolean
default: false
jobs:
build-mac:
runs-on: macos-latest
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Setup Node
uses: actions/setup-node@v3
with:
node-version: 20
- name: Install
run: npm install
- name: Setup Certificate
run: |
security import ./binaries/sign.p12 -P ${{ secrets.CERT_PASS }}
- name: Build
run: npm run build
- name: Rename
run: |
cp dist/eaglergrab-1.0.0-arm64.dmg dist/release-mac.dmg
- name: Upload
uses: actions/upload-artifact@v3
with:
name: release-mac.dmg
path: dist/release-mac.dmg
build-win:
runs-on: windows-latest
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Setup Node
uses: actions/setup-node@v3
with:
node-version: 20
- name: Install
run: npm install
- name: Build
run: npm run build
- name: Rename
run: |
cp "dist/eaglergrab Setup 1.0.0.exe" dist/setup-win.exe
- name: Upload
uses: actions/upload-artifact@v3
with:
name: setup-win.exe
path: dist/setup-win.exe
build-linux:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Setup Node
uses: actions/setup-node@v3
with:
node-version: 20
- name: Install
run: npm install
- name: Build
run: npm run build
- name: Rename
run: |
cp dist/eaglergrab-1.0.0.AppImage dist/release-linux.AppImage
- name: Upload
uses: actions/upload-artifact@v3
with:
name: release-linux.AppImage
path: dist/release-linux.AppImage
release:
runs-on: ubuntu-latest
needs: [build-mac, build-win, build-linux]
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Download Mac
uses: actions/download-artifact@v3
with:
name: release-mac.dmg
path: dist
- name: Download Windows
uses: actions/download-artifact@v3
with:
name: setup-win.exe
path: dist
- name: Download Linux
uses: actions/download-artifact@v3
with:
name: release-linux.AppImage
path: dist
- name: Release
uses: softprops/action-gh-release@v2
with:
files: |
dist/release-mac.dmg
dist/setup-win.exe
dist/release-linux.AppImage
prerelease: ${{ github.event.inputs.prerelease }}
generate_release_notes: true
tag_name: ${{ github.event.inputs.tag }}
name: ${{ github.event.inputs.tag }}